scripts: check.sh passes the federation check when it cannot connect; init.sh prints a needless hint under deploy.sh #3
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Two small problems in the operational scripts, both found while setting up the demo (#1).
1.
check.shreports "federation must be closed" asokwhen it cannot connectThe federation probe treats every result other than HTTP 200 as a pass, including curl errors. Before the demo's DNS existed,
check.shprinted:The other probes fail in that situation, so the overall exit status was still non-zero. But this line claims something it never checked, and it would mislead anyone reading only this line, or running the check against a proxy that drops the request.
Plan
Only an actual HTTP answer proves the endpoint is not served:
curl:*) → fail: "could not check federation (…)"200→ fail, as now2.
init.shtells you to restart Synapse whendeploy.shruns itAt the end,
init.shprints a next step: either "Synapse is running with the previous config. Apply this one with: docker compose up -d && docker compose restart synapse", or "Next: docker compose up -d, then open …". Whendeploy.shcalls it,deploy.shalready stops Synapse if the config changed and then starts the stack. So the hint is wrong advice in the deploy log, and it shows on every demo deploy.Plan
--no-hintoption toinit.shthat skips the final next-step message. The rendering itself is unchanged, and so is the default behaviour when you runinit.shby hand.deploy.shcall./scripts/init.sh --no-hint.I prefer an explicit option to hiding the hint when output is not a terminal: someone running
deploy.shin a terminal should not see it either.Verification
sh -non both scripts (CI already runs this)check.shagainst an unresolvable domain shows a FAIL for the federation probe; a normal run still shows allok