The forge's deploy speaks https to Semaphore and pins its CA (THE-106) #107

Merged
pit merged 4 commits from hermes/THE-106-semaphore-https into main 2026-12-01 15:13:50 +00:00
Owner

Semaphore serves a TLS listener from infra-cockpit now, and nothing on this estate can reach it over cleartext. This is the client half that keeps the forge's deploy working, and the ticket's done-when.

What changes

  • SEMAPHORE_API_URL defaults to https://10.12.0.143:3000.
  • start refuses any other scheme before the token file is written, and refuses a missing CA file. There is no -k and no http fallback to switch on: a certificate that does not verify is a red job and no request was made.
  • Every call carries --proto '=https' and --cacert scripts/semaphore-ca.crt, a copy of infra-cockpit's semaphore/service/files/ca.crt (identical bytes; the CA is public).
  • The status verb keeps reading the forge's own certificate from the system roots: it talks to the forge, not to Semaphore.
  • The script header no longer cites the TR-66 review's STD-2 as why the token crossed the LAN in cleartext.

Verified

make check exits 0 on this tree. The tests run the script against a TLS stub with its own CA and assert the refusals: a non-https URL sends nothing, a missing CA sends nothing, an unverifiable certificate is red with no request.

The design, the four ADR checks and the measured behaviour of the pinned 2.19.16 build are on the ticket as its design document (THE-106), and the decision to pin the CA this way is this repo's docs/adr/0010-the-semaphore-ca-is-committed-beside-the-deploy.md.

Merge order

Cockpit first (olympus/infra-cockpit, the TLS listener), then olympus/infra-tracker and this one. Between those merges a deploy here goes red at its first request and applies nothing — that is the no-fallback property working, not a broken job.

Rollback is a revert pull request: the job's own calls follow the code it runs.

Semaphore serves a TLS listener from `infra-cockpit` now, and nothing on this estate can reach it over cleartext. This is the client half that keeps the forge's deploy working, and the ticket's done-when. ## What changes - `SEMAPHORE_API_URL` defaults to `https://10.12.0.143:3000`. - `start` refuses any other scheme **before the token file is written**, and refuses a missing CA file. There is no `-k` and no http fallback to switch on: a certificate that does not verify is a red job and no request was made. - Every call carries `--proto '=https'` and `--cacert scripts/semaphore-ca.crt`, a copy of `infra-cockpit`'s `semaphore/service/files/ca.crt` (identical bytes; the CA is public). - The `status` verb keeps reading the forge's own certificate from the system roots: it talks to the forge, not to Semaphore. - The script header no longer cites the TR-66 review's STD-2 as why the token crossed the LAN in cleartext. ## Verified `make check` exits 0 on this tree. The tests run the script against a TLS stub with its own CA and assert the refusals: a non-https URL sends nothing, a missing CA sends nothing, an unverifiable certificate is red with no request. The design, the four ADR checks and the measured behaviour of the pinned 2.19.16 build are on the ticket as its `design` document ([THE-106](/THE/issues/THE-106)), and the decision to pin the CA this way is this repo's `docs/adr/0010-the-semaphore-ca-is-committed-beside-the-deploy.md`. ## Merge order Cockpit first (`olympus/infra-cockpit`, the TLS listener), then `olympus/infra-tracker` and this one. Between those merges a deploy here goes red at its first request and applies nothing — that is the no-fallback property working, not a broken job. Rollback is a revert pull request: the job's own calls follow the code it runs.
The forge's deploy speaks https to Semaphore and pins its CA (THE-106)
All checks were successful
plan / guest-plan-check (pull_request_target) Successful in 21s
plan / edge-plan-check (pull_request_target) Successful in 20s
plan / runner-guest-plan-check (pull_request_target) Successful in 19s
pr-checks / fmt-check (pull_request) Successful in 18s
pr-checks / env-check (pull_request) Successful in 20s
pr-checks / validate (pull_request) Successful in 20s
pr-checks / syntax-check (pull_request) Successful in 19s
pr-checks / docs-check (pull_request) Successful in 15s
8405f4058a
Semaphore serves https only now (infra-cockpit, semaphore/service), so the
deploy script stops being able to talk to it in cleartext: SEMAPHORE_API_URL
defaults to https, `start` refuses any other scheme before the token file is
written, and every call carries `--proto '=https'` and `--cacert` against the
CA committed beside the script. No `-k`, no http fallback.

The `status` verb keeps reading the forge's own certificate from the system
roots rather than the pinned CA: it talks to the forge, not to Semaphore.
The header no longer cites the TR-66 review's STD-2 as the reason the token
crossed the LAN in cleartext. The test suite runs the script against a TLS
stub with its own CA and asserts the refusals: a non-https URL sends nothing,
a missing CA file sends nothing, and a certificate that does not verify is a
red job with no request made.
Member

Review started (round 1/5) on 8405f4058a — reading the diff now.

**Review started** (round 1/5) on 8405f4058a623ef6f7069e850a7a585df2ccfa0d — reading the diff now.
bot-minos requested changes 2026-11-17 13:17:23 +00:00
Dismissed
bot-minos left a comment

olympus/infra-forge #107 — head 8405f40 — round 1/5 — 3 advisories, 0 blockers

Recommendation: fix

The two axes are reported separately; the recommendation is the advisory count's, not the weight's — no blocker stands.

Spec

Source: paperclip:THE-106, read live this round — GET /api/issues/70de29f9… → 200, its design document (/documents/design) → 200, GET /api/issues/70de29f9…/comments → 200, 3 entries; read 2026-11-17 13:10–13:17Z. The repo's docs/agents/issue-tracker.md names Vikunja for FO tickets; a THE- reference routes to the Paperclip control plane, which is where the ticket and its design resolved.

Requirement (THE-106) This change
2. SEMAPHORE_API_URL https in the repo's semaphore-deploy.sh and deploy workflow, no cleartext fallback met — https default, a refusal before the token file, and --proto '=https' --cacert on both Semaphore calls
Done when: no deploy workflow sends a Semaphore token over http met
Done when: script headers no longer cite TR-66 STD-2 met — and already true at the base (90fa0ed cites no TR-66/STD-2 either), so this clause was satisfied before the change; nothing was removed here and nothing needed to be
1. TLS listener (cockpit) / 3. ci-* expiry and rotation (store) other repositories; the design document carries 3's record

No spec findings. The claims in the PR body's Verified section are reproduced below.

Standards

ADVISORY — scripts/semaphore-deploy.sh:36, docs/runbooks/0001-deploy-and-rollback.md:434-435 — the cockpit path both name does not exist.
Both say the copy comes from infra-cockpit's semaphore/tls/ca.crt. Cockpit's PR #36 head (5a1a37e, read this round) carries it at semaphore/service/files/ca.crt, and THE-106's own comment at 13:10:46Z says "certificate and CA committed under semaphore/service/files/". The bytes are right — sha256 5a62c581… on both sides — so the pin works and only the reference is wrong; but that runbook line is the operator's recovery step for a certificate red, where a path that does not exist costs the turn. Smallest fix: name semaphore/service/files/ca.crt in both places.

ADVISORY — scripts/semaphore-deploy.sh:119 — a scheme-less address is printed whole, credential included.
"SEMAPHORE_API_URL is a ${BASE%%://*} address" yields the entire string when there is no ://. Driven at the head: SEMAPHORE_API_URL='user:hunter2@10.12.0.143:3000' prints SEMAPHORE_API_URL is a user:hunter2@10.12.0.143:3000 address. The function's own comment (:113-114) claims the opposite — "A scheme is named in the refusal and the rest of the address is not, because an address can carry a credential" — and ftp://user:hunter2@… does correctly print only ftp. Smallest fix: name ${BASE%%://*} only when the string contains ://, else say "an address with no scheme".

ADVISORY — no record of the pin in docs/adr/.
docs/index.md:12 says the Decisions section is updated when "a decision is made"; AGENTS.md:8-11 puts decisions that bind more than one repository under olympus/workshop's docs/adr/. This change decides to commit a copy of another repository's CA beside the script, against the alternatives the design weighed (system store, leaf-only pin, -k), and takes a lasting cost the runbook now encodes — a manual sha256sum comparison whenever cockpit rotates the CA. Neither docs/adr/ nor workshop's records carry it; the analysis lives on the ticket only. The precedent for the shape is docs/adr/0008-the-key-set-is-committed-beside-the-stack.md. Smallest fix: one record linking paperclip:THE-106's design — repo-local, or the workshop record if the board wants it org-wide.

Verified

  • refs/pull/107/head = 8405f40…, equal to the dispatch's SHA (read 13:20Z).
  • mise exec -- make check → exit 0 on the head tree: deploy-test 71 assertions, service-key 55, verify-stream 13, semaphore-deploy tests: every case passed, env-check, fmt-check, docs-check.
  • The same suite run bare fails 5 Ansible cases (Local RPC server did not start); under mise exec all pass. Environmental, not the change.
  • Mutants, in a scratch copy of the head: deleting require_tls from start reds the http, missing-CA and empty-CA cases; removing --cacert from CURL_TLS reds 14 cases. The suite can fail, and for the reasons claimed.
  • The committed CA is byte-identical to cockpit's semaphore/service/files/ca.crt at both 1e212d2 and the PR #36 head 5a1a37e (sha256 5a62c581…); it is CA:TRUE, pathlen:0, ECDSA P-256, name-constrained to 10.12.0.143/127.0.0.1; openssl verify of cockpit's committed leaf (SAN 10.12.0.143) against it answers OK — the pin verifies what the sibling PR will serve.
  • SEMAPHORE_API_URL appears in no env.map row, no .env.example entry and nowhere in the deploy workflow, so no store row re-introduces http behind the default.

Could not verify

  • Nothing ran against a live Semaphore or a live forge: the TLS listener is cockpit's change and is not merged. The trust chain is proved offline only (the CA against cockpit's committed leaf).

Named, not charged

  • The "nothing was sent" assertions in the http and missing-CA cases are vacuous on their own — a cleartext request to a TLS-only stub never reaches a handler, and the mutant that deletes require_tls still passes them. The message assertions in the same cases do catch it, so the suite holds; noted, not charged.
  • start_task's error path (scripts/semaphore-deploy.sh:165) prints $BASE whole. Pre-existing, untouched by this diff.
  • scripts/tests/semaphore-stub.py QuietServer.handle_error swallows every handler exception, not only a refused handshake — new, in test code, and no case turns on it.
  • .forgejo/workflows/deploy.yml is the deploy job, not a merge gate: pr-checks.yml and the plan workflows are untouched, and the diff there is four comment lines. The four things that define the gates — workflow file, context names, job names, and the target each job runs — did not move. Named so a human can overrule that reading.

Closing: Standards 3, Spec 0 — 3 findings, 0 blockers. Worst in Standards: the wrong cockpit path in the operator's recovery step (advisory, one-line fix). Worst in Spec: none.

<!-- minos review-loop: repo=olympus/infra-forge pr=107 head=8405f4058a623ef6f7069e850a7a585df2ccfa0d round=1/5 axes=standards,spec verdict=fix --> **olympus/infra-forge #107** — head `8405f40` — round 1/5 — 3 advisories, 0 blockers Recommendation: fix The two axes are reported separately; the recommendation is the advisory count's, not the weight's — no blocker stands. ## Spec Source: `paperclip:THE-106`, read live this round — `GET /api/issues/70de29f9…` → **200**, its `design` document (`/documents/design`) → **200**, `GET /api/issues/70de29f9…/comments` → **200**, 3 entries; read 2026-11-17 13:10–13:17Z. The repo's `docs/agents/issue-tracker.md` names Vikunja for `FO` tickets; a `THE-` reference routes to the Paperclip control plane, which is where the ticket and its design resolved. | Requirement (THE-106) | This change | | --- | --- | | 2. `SEMAPHORE_API_URL` https in the repo's `semaphore-deploy.sh` and deploy workflow, no cleartext fallback | **met** — https default, a refusal before the token file, and `--proto '=https' --cacert` on both Semaphore calls | | Done when: no deploy workflow sends a Semaphore token over http | **met** | | Done when: script headers no longer cite TR-66 STD-2 | **met** — and already true at the base (`90fa0ed` cites no TR-66/STD-2 either), so this clause was satisfied before the change; nothing was removed here and nothing needed to be | | 1. TLS listener (cockpit) / 3. `ci-*` expiry and rotation (store) | other repositories; the design document carries 3's record | No spec findings. The claims in the PR body's *Verified* section are reproduced below. ## Standards **ADVISORY — `scripts/semaphore-deploy.sh:36`, `docs/runbooks/0001-deploy-and-rollback.md:434-435` — the cockpit path both name does not exist.** Both say the copy comes from `infra-cockpit`'s `semaphore/tls/ca.crt`. Cockpit's PR #36 head (`5a1a37e`, read this round) carries it at `semaphore/service/files/ca.crt`, and THE-106's own comment at 13:10:46Z says "certificate and CA committed under `semaphore/service/files/`". The bytes are right — `sha256 5a62c581…` on both sides — so the pin works and only the reference is wrong; but that runbook line is the operator's recovery step for a certificate red, where a path that does not exist costs the turn. Smallest fix: name `semaphore/service/files/ca.crt` in both places. **ADVISORY — `scripts/semaphore-deploy.sh:119` — a scheme-less address is printed whole, credential included.** `"SEMAPHORE_API_URL is a ${BASE%%://*} address"` yields the entire string when there is no `://`. Driven at the head: `SEMAPHORE_API_URL='user:hunter2@10.12.0.143:3000'` prints `SEMAPHORE_API_URL is a user:hunter2@10.12.0.143:3000 address`. The function's own comment (`:113-114`) claims the opposite — "A scheme is named in the refusal and the rest of the address is not, because an address can carry a credential" — and `ftp://user:hunter2@…` does correctly print only `ftp`. Smallest fix: name `${BASE%%://*}` only when the string contains `://`, else say "an address with no scheme". **ADVISORY — no record of the pin in `docs/adr/`.** `docs/index.md:12` says the Decisions section is updated when "a decision is made"; `AGENTS.md:8-11` puts decisions that bind more than one repository under `olympus/workshop`'s `docs/adr/`. This change decides to commit a copy of another repository's CA beside the script, against the alternatives the design weighed (system store, leaf-only pin, `-k`), and takes a lasting cost the runbook now encodes — a manual `sha256sum` comparison whenever cockpit rotates the CA. Neither `docs/adr/` nor `workshop`'s records carry it; the analysis lives on the ticket only. The precedent for the shape is `docs/adr/0008-the-key-set-is-committed-beside-the-stack.md`. Smallest fix: one record linking `paperclip:THE-106`'s design — repo-local, or the workshop record if the board wants it org-wide. ## Verified - `refs/pull/107/head` = `8405f40…`, equal to the dispatch's SHA (read 13:20Z). - `mise exec -- make check` → **exit 0** on the head tree: deploy-test 71 assertions, service-key 55, verify-stream 13, `semaphore-deploy tests: every case passed`, env-check, fmt-check, docs-check. - The same suite run **bare** fails 5 Ansible cases (`Local RPC server did not start`); under `mise exec` all pass. Environmental, not the change. - Mutants, in a scratch copy of the head: deleting `require_tls` from `start` reds the http, missing-CA and empty-CA cases; removing `--cacert` from `CURL_TLS` reds 14 cases. The suite can fail, and for the reasons claimed. - The committed CA is byte-identical to cockpit's `semaphore/service/files/ca.crt` at both `1e212d2` and the PR #36 head `5a1a37e` (`sha256 5a62c581…`); it is `CA:TRUE, pathlen:0`, ECDSA P-256, name-constrained to `10.12.0.143`/`127.0.0.1`; `openssl verify` of cockpit's committed leaf (SAN `10.12.0.143`) against it answers **OK** — the pin verifies what the sibling PR will serve. - `SEMAPHORE_API_URL` appears in no `env.map` row, no `.env.example` entry and nowhere in the deploy workflow, so no store row re-introduces http behind the default. ## Could not verify - Nothing ran against a live Semaphore or a live forge: the TLS listener is cockpit's change and is not merged. The trust chain is proved offline only (the CA against cockpit's committed leaf). ## Named, not charged - The "nothing was sent" assertions in the http and missing-CA cases are vacuous on their own — a cleartext request to a TLS-only stub never reaches a handler, and the mutant that deletes `require_tls` still passes them. The message assertions in the same cases do catch it, so the suite holds; noted, not charged. - `start_task`'s error path (`scripts/semaphore-deploy.sh:165`) prints `$BASE` whole. Pre-existing, untouched by this diff. - `scripts/tests/semaphore-stub.py` `QuietServer.handle_error` swallows every handler exception, not only a refused handshake — new, in test code, and no case turns on it. - `.forgejo/workflows/deploy.yml` is the deploy job, not a merge gate: `pr-checks.yml` and the plan workflows are untouched, and the diff there is four comment lines. The four things that define the gates — workflow file, context names, job names, and the target each job runs — did not move. Named so a human can overrule that reading. Closing: **Standards 3, Spec 0** — 3 findings, 0 blockers. Worst in Standards: the wrong cockpit path in the operator's recovery step (advisory, one-line fix). Worst in Spec: none.
Author
Owner

Loop stopped — the fix dispatch produced no outcome for 20 minutes. Nothing else happens on this PR until its state label changes.

**Loop stopped** — the fix dispatch produced no outcome for 20 minutes. Nothing else happens on this PR until its state label changes.
Author
Owner

Waiting — queued behind olympus/infra-silo#39 (one review run at a time). The review run resumes on its own at Tue 1 Dec, 14:39 (Europe/Madrid); nothing is needed from you. This retry does not count as a review round.

**Waiting** — queued behind olympus/infra-silo#39 (one review run at a time). The review run resumes on its own at Tue 1 Dec, 14:39 (Europe/Madrid); nothing is needed from you. This retry does not count as a review round.
Member

Review started (round 0/5) on 8405f4058a — reading the diff now.

**Review started** (round 0/5) on 8405f4058a623ef6f7069e850a7a585df2ccfa0d — reading the diff now.
bot-minos requested changes 2026-12-01 13:49:23 +00:00
Dismissed
bot-minos left a comment

olympus/infra-forge #107 — head 8405f40 — round 2/5 — 3 advisories, 0 blockers

Recommendation: fix

The tree has not moved since round 1: same head, same diff, same body. This is the thread's second review, so the header says 2/5 while the dispatch's sign-on comment said 0/5 — the loop's counter restarts when a review/* label is moved by hand, and the review list is the ledger. Every finding below was re-driven at this head this round, not copied out of round 1's body, and the count still trips the volume rule, so the word does not move.

Spec

Source: paperclip:THE-106, read live this round (GET /api/issues/THE-106 → 200; /documents → 200, the design document Native TLS on Semaphore (143), pinned by every client, no cleartext fallback); the PR body; and olympus/infra-cockpit PR #36 at head 5a1a37e for the CA's origin.

Requirement (THE-106) This change Status
2 — SEMAPHORE_API_URL https in every repo's semaphore-deploy.sh and deploy workflow, no cleartext fallback https default (scripts/semaphore-deploy.sh:65), a refusal before the token file (:189 into :116-123), --proto '=https' --cacert on both Semaphore curls (:161, :173) met
Done when — no deploy workflow sends a Semaphore token over http the deploy job carries no address of its own (.forgejo/workflows/deploy.yml:62-72) and the script refuses a non-https one met
Done when — the script headers no longer cite TR-66 STD-2 neither the base 90fa0ed nor this head cites TR-66 or STD-2; the clause was already satisfied met, vacuously
1 — the TLS listener (cockpit) / 3 — ci-* expiry and rotation (store) other repositories; the design document records 3 out of scope

No spec findings.

Standards

Standards sources: AGENTS.md:5-11 (§Decisions), AGENTS.md:24-27 (§Code comments), docs/index.md:12, docs/adr/index.md, and the org records at olympus/workshop origin/main docs/adr/ (15 files, read at the forge's main).

AGENTS.md:24-27 (§Code comments) is passed: the added header prose continues a header that is 52 comment lines long at the base, so it extends an existing convention rather than introducing one.

ADVISORY — scripts/semaphore-deploy.sh:36, docs/runbooks/0001-deploy-and-rollback.md:434-435, PR body What changes bullet 3 — the cockpit path all three name does not exist.
They say the copy comes from infra-cockpit's semaphore/tls/ca.crt. At cockpit PR #36's head 5a1a37e the file is semaphore/service/files/ca.crt, and semaphore/tls/ is not in that tree at all. The bytes are right — sha256 5a62c581… on both sides — so the pin works and only the reference is wrong; but it is wrong where an operator reads it, in the runbook's recovery step for a certificate red, and a path that does not exist costs the turn it was meant to save. Smallest fix: name semaphore/service/files/ca.crt at all three sites.

ADVISORY — scripts/semaphore-deploy.sh:119 — a scheme-less address is printed whole, credential included, against the comment at :113-114.
"SEMAPHORE_API_URL is a ${BASE%%://*} address" yields the entire string when there is no ://. Driven at this head: SEMAPHORE_API_URL='user:hunter2@10.12.0.143:3000' prints SEMAPHORE_API_URL is a user:hunter2@10.12.0.143:3000 address; ftp://user:hunter2@… correctly prints only ftp. The function's own comment says the opposite in as many words — a scheme is named and the rest of the address is not, because an address can carry a credential. Smallest fix: name the scheme only when $BASE contains ://, else say an address with no scheme.

ADVISORY — no record of the pin in docs/adr/ or in olympus/workshop's docs/adr/.
AGENTS.md:7-10 sends a decision that binds more than one repository to olympus/workshop docs/adr/; docs/index.md:12 says the Decisions section is updated when "a decision is made". This change commits a copy of another repository's CA beside the script, against the alternatives the design weighed (system store, leaf-only pin, -k), and takes a lasting cost the runbook now encodes — a manual sha256sum comparison whenever cockpit rotates the CA (docs/runbooks/0001-deploy-and-rollback.md:440). Neither the repo's nine records nor the org's fifteen carry it; the analysis lives on the ticket only, and a ticket is not read by anyone working in the repo. The precedent for the shape is docs/adr/0008-the-key-set-is-committed-beside-the-stack.md. Smallest fix: one record linking paperclip:THE-106's design — repo-local, or the workshop record if the board wants it org-wide.

Verified

  • refs/pull/107/head = 8405f40…, equal to the dispatch's SHA (fetched at 14:46Z, re-read before this review).
  • mise exec -- make check → exit 0 at this head: semaphore-deploy tests: every case passed, deploy-workflow tests: 71 assertions, 0 FAILED, service-key tests: 55 assertions, 0 FAILED, the plan-workflow and snapshot suites green, docs-check: all 5 assertions hold.
  • Two mutants on a scratch copy of the head, which was not this worktree: deleting require_tls from start → suite exit 1, 18 FAIL lines, among them the http, no-scheme, missing-CA and empty-CA cases; removing --cacert "$CA" from CURL_TLS → exit 1, 14 FAIL lines. The suite can fail, and for the reasons the PR claims.
  • The committed CA is byte-identical to cockpit PR #36's semaphore/service/files/ca.crt (sha256 5a62c5816adbd382d4bfce8fe1ccb774f7e10173b391abafb90acf2c516fb13a both sides), and openssl verify of cockpit's committed leaf (SAN 10.12.0.143) against it answers OK — the pin verifies what the sibling PR will serve.
  • Finding 2 driven at the head, quoted above. Finding 1's path driven against cockpit PR #36's tree, where it is absent.
  • docs/adr/ holds nine records and olympus/workshop origin/main docs/adr/ fifteen; none states this pin.

Could not verify

  • Nothing ran against a live Semaphore or a live forge: cockpit PR #36 is not merged, so the TLS listener does not exist yet. The trust chain is proved offline only.

Named, not charged

  • The "nothing was sent" assertions in the http and missing-CA cases are vacuous on their own — a cleartext request to a TLS-only stub never reaches a handler. The message assertions beside them in the same cases do catch the mutant, and they are among the 18 the require_tls deletion reds, so the suite holds. Noted, not charged.
  • start_task's error path (scripts/semaphore-deploy.sh:165) prints $BASE whole. Pre-existing, untouched by this diff; the same class as finding 2.
  • scripts/tests/semaphore-stub.py QuietServer.handle_error swallows every handler exception, not only a refused handshake — new, in test code, and no case turns on it.
  • .forgejo/workflows/deploy.yml is the deploy job, not a merge gate: pr-checks.yml and the plan workflows are untouched, and the delta there is four comment lines. The four things that define the gates — workflow file, context names, job names, and the target each job runs — did not move. Named so a human can overrule that reading.

Closing: Standards 3, Spec 0 — 3 findings, 0 blockers. Worst in Standards: the wrong cockpit path in the operator's recovery step (advisory, a three-site one-line fix). Worst in Spec: none. The recommendation follows the advisory count (3 ≥ 3) and not the weight — no blocker stands. This dispatch binds the review state to the recommendation, so REQUEST_CHANGES stands beside zero blockers; the count moved it.

<!-- minos review-loop: repo=olympus/infra-forge pr=107 head=8405f4058a623ef6f7069e850a7a585df2ccfa0d round=2/5 axes=standards,spec --> **olympus/infra-forge #107** — head `8405f40` — round 2/5 — 3 advisories, 0 blockers Recommendation: fix The tree has not moved since round 1: same head, same diff, same body. This is the thread's second review, so the header says 2/5 while the dispatch's sign-on comment said 0/5 — the loop's counter restarts when a `review/*` label is moved by hand, and the review list is the ledger. Every finding below was re-driven at this head this round, not copied out of round 1's body, and the count still trips the volume rule, so the word does not move. ## Spec Source: `paperclip:THE-106`, read live this round (`GET /api/issues/THE-106` → **200**; `/documents` → **200**, the `design` document *Native TLS on Semaphore (143), pinned by every client, no cleartext fallback*); the PR body; and `olympus/infra-cockpit` PR #36 at head `5a1a37e` for the CA's origin. | Requirement (THE-106) | This change | Status | | --- | --- | --- | | 2 — `SEMAPHORE_API_URL` https in every repo's `semaphore-deploy.sh` and deploy workflow, no cleartext fallback | https default (`scripts/semaphore-deploy.sh:65`), a refusal before the token file (`:189` into `:116-123`), `--proto '=https' --cacert` on both Semaphore curls (`:161`, `:173`) | **met** | | Done when — no deploy workflow sends a Semaphore token over http | the deploy job carries no address of its own (`.forgejo/workflows/deploy.yml:62-72`) and the script refuses a non-https one | **met** | | Done when — the script headers no longer cite TR-66 STD-2 | neither the base `90fa0ed` nor this head cites TR-66 or STD-2; the clause was already satisfied | **met, vacuously** | | 1 — the TLS listener (cockpit) / 3 — `ci-*` expiry and rotation (store) | other repositories; the design document records 3 | out of scope | No spec findings. ## Standards Standards sources: `AGENTS.md:5-11` (§Decisions), `AGENTS.md:24-27` (§Code comments), `docs/index.md:12`, `docs/adr/index.md`, and the org records at `olympus/workshop` `origin/main` `docs/adr/` (15 files, read at the forge's `main`). `AGENTS.md:24-27` (§Code comments) is passed: the added header prose continues a header that is 52 comment lines long at the base, so it extends an existing convention rather than introducing one. **ADVISORY — `scripts/semaphore-deploy.sh:36`, `docs/runbooks/0001-deploy-and-rollback.md:434-435`, PR body *What changes* bullet 3 — the cockpit path all three name does not exist.** They say the copy comes from `infra-cockpit`'s `semaphore/tls/ca.crt`. At cockpit PR #36's head `5a1a37e` the file is `semaphore/service/files/ca.crt`, and `semaphore/tls/` is not in that tree at all. The bytes are right — `sha256 5a62c581…` on both sides — so the pin works and only the reference is wrong; but it is wrong where an operator reads it, in the runbook's recovery step for a certificate red, and a path that does not exist costs the turn it was meant to save. Smallest fix: name `semaphore/service/files/ca.crt` at all three sites. **ADVISORY — `scripts/semaphore-deploy.sh:119` — a scheme-less address is printed whole, credential included, against the comment at `:113-114`.** `"SEMAPHORE_API_URL is a ${BASE%%://*} address"` yields the entire string when there is no `://`. Driven at this head: `SEMAPHORE_API_URL='user:hunter2@10.12.0.143:3000'` prints `SEMAPHORE_API_URL is a user:hunter2@10.12.0.143:3000 address`; `ftp://user:hunter2@…` correctly prints only `ftp`. The function's own comment says the opposite in as many words — a scheme is named and the rest of the address is not, because an address can carry a credential. Smallest fix: name the scheme only when `$BASE` contains `://`, else say `an address with no scheme`. **ADVISORY — no record of the pin in `docs/adr/` or in `olympus/workshop`'s `docs/adr/`.** `AGENTS.md:7-10` sends a decision that binds more than one repository to `olympus/workshop` `docs/adr/`; `docs/index.md:12` says the Decisions section is updated when "a decision is made". This change commits a copy of another repository's CA beside the script, against the alternatives the design weighed (system store, leaf-only pin, `-k`), and takes a lasting cost the runbook now encodes — a manual `sha256sum` comparison whenever cockpit rotates the CA (`docs/runbooks/0001-deploy-and-rollback.md:440`). Neither the repo's nine records nor the org's fifteen carry it; the analysis lives on the ticket only, and a ticket is not read by anyone working in the repo. The precedent for the shape is `docs/adr/0008-the-key-set-is-committed-beside-the-stack.md`. Smallest fix: one record linking `paperclip:THE-106`'s design — repo-local, or the workshop record if the board wants it org-wide. ## Verified - `refs/pull/107/head` = `8405f40…`, equal to the dispatch's SHA (fetched at 14:46Z, re-read before this review). - `mise exec -- make check` → **exit 0** at this head: `semaphore-deploy tests: every case passed`, `deploy-workflow tests: 71 assertions, 0 FAILED`, `service-key tests: 55 assertions, 0 FAILED`, the plan-workflow and snapshot suites green, `docs-check: all 5 assertions hold`. - Two mutants on a scratch copy of the head, which was not this worktree: deleting `require_tls` from `start` → suite **exit 1**, 18 FAIL lines, among them the http, no-scheme, missing-CA and empty-CA cases; removing `--cacert "$CA"` from `CURL_TLS` → **exit 1**, 14 FAIL lines. The suite can fail, and for the reasons the PR claims. - The committed CA is byte-identical to cockpit PR #36's `semaphore/service/files/ca.crt` (`sha256 5a62c5816adbd382d4bfce8fe1ccb774f7e10173b391abafb90acf2c516fb13a` both sides), and `openssl verify` of cockpit's committed leaf (SAN `10.12.0.143`) against it answers **OK** — the pin verifies what the sibling PR will serve. - Finding 2 driven at the head, quoted above. Finding 1's path driven against cockpit PR #36's tree, where it is absent. - `docs/adr/` holds nine records and `olympus/workshop` `origin/main` `docs/adr/` fifteen; none states this pin. ## Could not verify - Nothing ran against a live Semaphore or a live forge: cockpit PR #36 is not merged, so the TLS listener does not exist yet. The trust chain is proved offline only. ## Named, not charged - The "nothing was sent" assertions in the http and missing-CA cases are vacuous on their own — a cleartext request to a TLS-only stub never reaches a handler. The message assertions beside them in the same cases do catch the mutant, and they are among the 18 the `require_tls` deletion reds, so the suite holds. Noted, not charged. - `start_task`'s error path (`scripts/semaphore-deploy.sh:165`) prints `$BASE` whole. Pre-existing, untouched by this diff; the same class as finding 2. - `scripts/tests/semaphore-stub.py` `QuietServer.handle_error` swallows every handler exception, not only a refused handshake — new, in test code, and no case turns on it. - `.forgejo/workflows/deploy.yml` is the deploy job, not a merge gate: `pr-checks.yml` and the plan workflows are untouched, and the delta there is four comment lines. The four things that define the gates — workflow file, context names, job names, and the target each job runs — did not move. Named so a human can overrule that reading. Closing: **Standards 3, Spec 0** — 3 findings, 0 blockers. Worst in Standards: the wrong cockpit path in the operator's recovery step (advisory, a three-site one-line fix). Worst in Spec: none. The recommendation follows the advisory count (3 ≥ 3) and not the weight — no blocker stands. This dispatch binds the review state to the recommendation, so `REQUEST_CHANGES` stands beside zero blockers; the count moved it.
Author
Owner

Waiting — queued behind olympus/infra-silo#39 (one fix run at a time). The fix run resumes on its own at Tue 1 Dec, 14:49 (Europe/Madrid); nothing is needed from you. This retry does not count as a review round.

**Waiting** — queued behind olympus/infra-silo#39 (one fix run at a time). The fix run resumes on its own at Tue 1 Dec, 14:49 (Europe/Madrid); nothing is needed from you. This retry does not count as a review round.
Member

Acknowledged (round 0/5) — fixing now; what changed and how I verified it follows.

**Acknowledged** (round 0/5) — fixing now; what changed and how I verified it follows.
The review charged the path at two sites in the tree, and the PR body at a
third: they said the copy comes from `infra-cockpit`'s `semaphore/tls/ca.crt`,
and that tree carries no `semaphore/tls/`. The file is at
`semaphore/service/files/ca.crt` — same bytes, sha256 5a62c581… — so the pin
works and only the reference was wrong, in the runbook's recovery step for a
certificate red, where a path that does not exist costs the turn it was meant
to save.
`${BASE%%://*}` is the whole string when there is no `://`, so a scheme-less
address was printed back whole — credential included — which is the opposite of
what the comment above the function claims, and it is printed before anything
is sent but into a job log all the same.

The scheme is now named only when the address has one; otherwise the refusal
says the address carries no scheme. The suite pins both directions: a
scheme-less address is red with that sentence, and neither it nor an http
address carrying a credential puts the credential in the output.
ADR 0010 records the pinned CA, and what rotating it costs (THE-106)
All checks were successful
plan / guest-plan-check (pull_request_target) Successful in 25s
plan / edge-plan-check (pull_request_target) Successful in 34s
plan / runner-guest-plan-check (pull_request_target) Successful in 26s
pr-checks / env-check (pull_request) Successful in 19s
pr-checks / fmt-check (pull_request) Successful in 18s
pr-checks / validate (pull_request) Successful in 27s
pr-checks / syntax-check (pull_request) Successful in 22s
pr-checks / docs-check (pull_request) Successful in 22s
76c839c069
The review charged that committing another repository's CA beside the deploy is
a decision with a lasting cost and no record: the analysis lived only on the
ticket's `design` document, which nobody working in this tree reads. ADR 0010
states the mechanism, the alternatives the design weighed (the system store, a
leaf-only pin, fetching the CA at job time, cleartext) and the rotation cost the
runbook now encodes, and the index gains its row.
Member

Fix round — head 76c839c — the review I was sent is minos round 2/5 at 8405f40: 0 blockers, 3 advisories. The dispatch's wording said blocking findings; the tally is the review's own, and the count rule (3 advisories ≥ 3) is what moved the state. All three are cleared.

# Finding Clearing change Commit
1 the cockpit path semaphore/tls/ca.crt exists in no tree semaphore/service/files/ca.crt at all three sites: the script header, the runbook's recovery step (paragraph reflowed, 10 lines to 10), and the PR body's What changes bullet 3 — body edit, no commit b886aa9
2 a scheme-less address printed whole, credential included require_tls names the scheme only when $BASE carries one and says "an address with no scheme" otherwise; the refusal sentence is composed once instead of twice 7b6e944
3 no record of the pin in docs/adr/ ADR 0010, repo-local (the finding's own smaller option; its Consequences say a record binding another client too would be olympus/workshop's), with its row in docs/adr/index.md 76c839c

Verified — mise exec -- make check → rc=0 at 76c839c: semaphore-deploy tests: every case passed (119 assertions), deploy-workflow tests: 71 assertions, 0 FAILED, service-key tests: 55 assertions, 0 FAILED, verify-stream: 13 passed, 0 failed, the snapshot and plan-workflow suites green, docs-check: all 5 assertions hold (adr-index 10 rows and 10 records, the same set both ways).

Finding 2, both directions. Before the fix the new assertions failed exactly as charged: FAIL the red says the address carries no scheme (missing [is an address with no scheme]; got: SEMAPHORE_API_URL is a 127.0.0.1:40185 address; …) and FAIL and does not repeat the address, credential included (the output repeats [hunter2]); after it, green. Mutant on a scratch copy of the head, the scheme-less arm reverted to ${BASE}: rc=1, those two assertions red again.

Finding 1's path, checked against the source rather than copied. infra-cockpit's refs/pull/36/head (5a1a37e) carries semaphore/service/files/ca.crt and no semaphore/tls/; the bytes are identical on both sides (sha256 5a62c581…). The PR body was re-read after the edit and matches what was sent.

Checks at 76c839c — all eight contexts are success: pr-checks env-check, fmt-check, validate, syntax-check, docs-check; plan guest-plan-check, edge-plan-check, runner-guest-plan-check.

Named, not fixed. scripts/tests/deploy-workflow.sh:56's assert_contains pipes a whole file into grep -qF under set -o pipefail, so grep's early exit can SIGPIPE printf and report a match as missing — printf: write error: Broken pipe followed by a FAIL, which is what this head's first check run showed and a re-run cleared. Reproduced against the base revision's own script content: 41 of 300 runs returned rc 141. Pre-existing, untouched by this diff, and a ticket of its own rather than this round's work.

Review of my own diff. The two claude -p sub-agents the code-review skill runs both answered with a quota notice, so I ran both axes myself: Standards against AGENTS.md, docs/index.md and ADR 0008's shape (it found the duplicated refusal sentence, now composed once; added lines sit inside the files' own width registers), Spec against the three findings above.

Nothing disagreed with, nothing left undone.

**Fix round** — head `76c839c` — the review I was sent is minos round 2/5 at `8405f40`: **0 blockers, 3 advisories**. The dispatch's wording said blocking findings; the tally is the review's own, and the count rule (3 advisories ≥ 3) is what moved the state. All three are cleared. | # | Finding | Clearing change | Commit | | --- | --- | --- | --- | | 1 | the cockpit path `semaphore/tls/ca.crt` exists in no tree | `semaphore/service/files/ca.crt` at all three sites: the script header, the runbook's recovery step (paragraph reflowed, 10 lines to 10), and the PR body's *What changes* bullet 3 — body edit, no commit | `b886aa9` | | 2 | a scheme-less address printed whole, credential included | `require_tls` names the scheme only when `$BASE` carries one and says "an address with no scheme" otherwise; the refusal sentence is composed once instead of twice | `7b6e944` | | 3 | no record of the pin in `docs/adr/` | ADR 0010, repo-local (the finding's own smaller option; its Consequences say a record binding another client too would be `olympus/workshop`'s), with its row in `docs/adr/index.md` | `76c839c` | **Verified** — `mise exec -- make check` → **rc=0** at `76c839c`: `semaphore-deploy tests: every case passed` (119 assertions), `deploy-workflow tests: 71 assertions, 0 FAILED`, `service-key tests: 55 assertions, 0 FAILED`, `verify-stream: 13 passed, 0 failed`, the snapshot and plan-workflow suites green, `docs-check: all 5 assertions hold` (`adr-index 10 rows and 10 records, the same set both ways`). **Finding 2, both directions.** Before the fix the new assertions failed exactly as charged: `FAIL the red says the address carries no scheme (missing [is an address with no scheme]; got: SEMAPHORE_API_URL is a 127.0.0.1:40185 address; …)` and `FAIL and does not repeat the address, credential included (the output repeats [hunter2])`; after it, green. Mutant on a scratch copy of the head, the scheme-less arm reverted to `${BASE}`: `rc=1`, those two assertions red again. **Finding 1's path, checked against the source rather than copied.** `infra-cockpit`'s `refs/pull/36/head` (`5a1a37e`) carries `semaphore/service/files/ca.crt` and no `semaphore/tls/`; the bytes are identical on both sides (`sha256 5a62c581…`). The PR body was re-read after the edit and matches what was sent. **Checks at `76c839c`** — all eight contexts are success: `pr-checks` env-check, fmt-check, validate, syntax-check, docs-check; `plan` guest-plan-check, edge-plan-check, runner-guest-plan-check. **Named, not fixed.** `scripts/tests/deploy-workflow.sh:56`'s `assert_contains` pipes a whole file into `grep -qF` under `set -o pipefail`, so grep's early exit can SIGPIPE `printf` and report a match as missing — `printf: write error: Broken pipe` followed by a FAIL, which is what this head's first check run showed and a re-run cleared. Reproduced against the base revision's own script content: 41 of 300 runs returned rc 141. Pre-existing, untouched by this diff, and a ticket of its own rather than this round's work. **Review of my own diff.** The two `claude -p` sub-agents the `code-review` skill runs both answered with a quota notice, so I ran both axes myself: Standards against `AGENTS.md`, `docs/index.md` and ADR 0008's shape (it found the duplicated refusal sentence, now composed once; added lines sit inside the files' own width registers), Spec against the three findings above. Nothing disagreed with, nothing left undone.
Member

Review started (round 1/5) on 76c839c069 — reading the diff now.

**Review started** (round 1/5) on 76c839c069a27914e70a08d9309e48e6b4985e5d — reading the diff now.
bot-minos approved these changes 2026-12-01 14:33:48 +00:00
bot-minos left a comment

olympus/infra-forge #107 — head 76c839c — round 3/5 — 1 advisory, 0 blockers

Recommendation: merge

This dispatch numbered the round 1/5; the review list carries two reviews on this thread (8405f40, rounds 1 and 2), so the ledger's round is 3 and the header says so. The sign-on comment keeps the dispatch's number, as it is posted before the ledger is read.

The head moved since round 2 (8405f40 → 76c839c, stacked: git merge-base --is-ancestor 8405f40 76c839c is true). All three round-2 advisories are cleared, each re-driven at this head below. One advisory is new.

Spec

Source: paperclip:THE-106, read live this round — GET /api/issues/THE-106 → 200 (11 820 B), /documents → 200, the design document Design: native TLS on Semaphore (143), pinned by every client (8 015 chars), /comments → 200, 4 entries; read 2026-12-01 14:33Z. The PR body; and olympus/infra-cockpit PR #36 at head 5a1a37eea4afec411797bc35c67c94099dc13ef6 for the CA's origin (fetched this round).

Requirement (THE-106) This change Status
2 — SEMAPHORE_API_URL https in semaphore-deploy.sh and the deploy workflow, no cleartext fallback https default (scripts/semaphore-deploy.sh:65), the refusal before the token file (:193 into :117-127), --proto '=https' --tlsv1.2 --cacert on both Semaphore curls (:165, :177) met
Done when — no deploy workflow sends a Semaphore token over http the job carries no address of its own and the script refuses a non-https one; a workflow case now asserts no http://, no --insecure, no SKIP_VERIFY (scripts/tests/deploy-workflow.sh:266-268) met
Done when — the script headers no longer cite TR-66 STD-2 neither the base 90fa0ed nor this head cites TR-66 or STD-2 met, vacuously
1 — the TLS listener (cockpit) / 3 — ci-* expiry (store) other repositories out of scope

No spec findings. The PR body's What changes bullet 3 now names semaphore/service/files/ca.crt, which is the path cockpit publishes at its head.

Standards

Sources read at the head worktree: AGENTS.md:7-10 (§Decisions), AGENTS.md:24-27 (§Code comments), docs/index.md:12, docs/adr/index.md.

Round-2 findings, re-driven

# Round-2 finding Resolution at 76c839c Evidence
1 the cockpit path named at three sites does not exist b886aa9 — semaphore/service/files/ca.crt at all three scripts/semaphore-deploy.sh:36, docs/runbooks/0001-deploy-and-rollback.md:435, PR body bullet 3. Cockpit at 5a1a37e: semaphore/service/files/ca.crt → 200, semaphore/tls/ca.crt → The target couldn't be found. Census: grep -rF 'semaphore/tls/' over the tree → 0 files.
2 a scheme-less address printed whole, credential included 7b6e944 — require_tls names the scheme only when the string carries one scripts/semaphore-deploy.sh:119-124. Driven: SEMAPHORE_API_URL='user:hunter2@10.12.0.143:3000' → SEMAPHORE_API_URL is an address with no scheme; …, hunter2 absent; http://user:hunter2@… → is a http address, hunter2 absent; ftp://… → is a ftp address. Mutant M3 (the scheme-less arm reverted to ${BASE}) reds exactly the two cases written for it, scripts/tests/semaphore-deploy.test.sh:225 and :229.
3 no record of the pin in docs/adr/ 76c839c — ADR 0010 plus its index row docs/adr/0010-the-semaphore-ca-is-committed-beside-the-deploy.md:1-65, docs/adr/index.md:18; docs-check reports adr-index 10 rows and 10 records, the same set both ways.

ADVISORY — scripts/semaphore-deploy.sh:38, docs/runbooks/0001-deploy-and-rollback.md:436, docs/adr/0010-the-semaphore-ca-is-committed-beside-the-deploy.md:6-7 — three prose enumerations of the pin's options omit one of them.

Each says every Semaphore call carries --proto '=https' and --cacert. The options the code actually sets are three: CURL_TLS=(--proto '=https' --tlsv1.2 --cacert "$CA") at scripts/semaphore-deploy.sh:126. The omission is of --tlsv1.2, the TLS floor. The sentence is incomplete rather than false — the two named options are the ones the neighbouring claims rest on (no cleartext, and the pinned root) — so this is advice, not a defect: it is the third time a reader meets a list that stops short. Smallest fix: add --tlsv1.2 to the three lists, or say "carries --proto '=https', a TLS 1.2 floor and --cacert".

Verified

  • refs/pull/107/head = 76c839c069a27914e70a08d9309e48e6b4985e5d, equal to the dispatch's SHA — git ls-remote read when the round opened and again after the mutation wave; both reads agree.
  • The round's delta is git diff 8405f40 76c839c: 5 files, +102/−16, confined to the three clearing changes (ADR + index row, the runbook paragraph, the require_tls arm and its two cases). No hunk outside them.
  • mise exec -- make check → the whole floor green at this head: semaphore-deploy tests: every case passed, deploy-workflow tests: 71 assertions, 0 FAILED, service-key tests: 55 assertions, 0 FAILED, verify-stream: 13 passed, 0 failed, snapshot tests: every case passed, plan workflow tests: every case passed, docs-check: all 5 assertions hold.
  • The suite can fail, and for the reasons the change claims — three mutants on this worktree, each restored and the blob asserted against git show HEAD:<path> before the next:
    • M1, require_tls deleted from start → suite rc=1.
    • M2, --cacert "$CA" dropped from CURL_TLS → suite rc=1.
    • M3, the scheme-less arm reverted to ${BASE} → suite rc=1, and the two named assertions are among the reds.
    • M4, --insecure added to a real step of deploy.yml → deploy-workflow rc=1, FAIL … it does not skip verification (found [--insecure]). (A first attempt appended a comment line; deploy-workflow.sh:76 strips comments before asserting, so that mutant was void and is not counted.)
  • require_tls driven by hand at this head, five inputs: scheme-less with a credential, scheme-less plain, http:// with a credential, ftp:// with a credential, and a missing CA file. Each exits 1 before any request, names the scheme or the missing CA, and repeats no credential.
  • The committed CA is byte-identical to cockpit's at 5a1a37e: sha256 5a62c5816adbd382d4bfce8fe1ccb774f7e10173b391abafb90acf2c516fb13a both sides, and the file served over the forge's contents route is byte-identical to the one in this tree. openssl x509 on it: CA:TRUE, pathlen:0, ECDSA P-256, name-constrained to 10.12.0.143 and 127.0.0.1.
  • CI at 76c839c: the newest status per context is success for all eight — pr-checks env-check, fmt-check, validate, syntax-check, docs-check; plan guest-plan-check, edge-plan-check, runner-guest-plan-check.
  • docs/adr/ holds 10 records and docs/adr/index.md 10 rows; the ADR's Consequences :47-50 and the runbook's recovery step :437-442 describe the same procedure in the same order.

Could not verify

  • Nothing ran against a live Semaphore or a live forge: olympus/infra-cockpit#36 is open, so the TLS listener does not exist yet. The trust chain is proved offline only — the pinned CA against cockpit's committed leaf and its committed CA.
  • The deploy job itself has never executed against this tree; it runs on merge, not on the pull request.

Named, not charged

  • scripts/tests/deploy-workflow.sh:55-57 — assert_contains pipes a whole file into grep -qF under set -o pipefail at :36, so an early grep exit can SIGPIPE printf and report a match as missing. The fix round reported this (41 of 300 runs, rc 141, at the base revision). I could not reproduce it: 200 synthetic runs at four haystack sizes from 64 KiB to 4 MiB all returned 0. Pre-existing on a line this diff does not touch; named so it is not read as covered.
  • scripts/tests/semaphore-stub.py QuietServer.handle_error swallows every handler exception, not only a refused handshake — new in test code at an earlier round, and no case turns on it.
  • scripts/semaphore-deploy.sh:169 — start_task's error path prints ${BASE} whole. Pre-existing, untouched by this diff; the same class as round-2 finding 2, which fixed the refusal and not this line.
  • .forgejo/workflows/deploy.yml — this round's delta does not touch it. Across the change it is four comment lines, and the four things that define the job — the workflow file, the context names, the job names, and the target each job runs — did not move. Named so a human can overrule that reading.

Escalation

ADR 0010 is a new binding record in a repository, which is an escalation class under the Reviewer charter. Opened as THE-109 (status: todo, assigneeAgentId the Board's, parentId: null), read back this round after creation. The card's substance: the record's own Consequences (docs/adr/0010-…:51-54) and Update when (:62) defer the org-wide record to olympus/workshop until "a second repository pins the same file" — and the merge order this PR announces puts olympus/infra-tracker in before it does, so the deferral expires on arrival.

Per the dispatch, the change's class is not a reason to withhold an approval: the state and label below are the findings', and merging remains the board's gate.

Closing: Standards 1, Spec 0 — 1 finding, 0 blockers. Worst in Standards: the three prose lists that omit --tlsv1.2 (advisory, one word each). Worst in Spec: none. One advisory is short of the three that would move the recommendation.

<!-- minos review-loop: repo=olympus/infra-forge pr=107 head=76c839c069a27914e70a08d9309e48e6b4985e5d round=3/5 axes=standards,spec verdict=merge --> **olympus/infra-forge #107** — head `76c839c` — round 3/5 — 1 advisory, 0 blockers Recommendation: merge This dispatch numbered the round `1/5`; the review list carries two reviews on this thread (`8405f40`, rounds 1 and 2), so the ledger's round is 3 and the header says so. The sign-on comment keeps the dispatch's number, as it is posted before the ledger is read. The head moved since round 2 (`8405f40` → `76c839c`, stacked: `git merge-base --is-ancestor 8405f40 76c839c` is true). All three round-2 advisories are cleared, each re-driven at this head below. One advisory is new. ## Spec Source: `paperclip:THE-106`, read live this round — `GET /api/issues/THE-106` → **200** (11 820 B), `/documents` → **200**, the `design` document *Design: native TLS on Semaphore (143), pinned by every client* (8 015 chars), `/comments` → **200**, 4 entries; read 2026-12-01 14:33Z. The PR body; and `olympus/infra-cockpit` PR #36 at head `5a1a37eea4afec411797bc35c67c94099dc13ef6` for the CA's origin (fetched this round). | Requirement (THE-106) | This change | Status | | --- | --- | --- | | 2 — `SEMAPHORE_API_URL` https in `semaphore-deploy.sh` and the deploy workflow, no cleartext fallback | https default (`scripts/semaphore-deploy.sh:65`), the refusal before the token file (`:193` into `:117-127`), `--proto '=https' --tlsv1.2 --cacert` on both Semaphore curls (`:165`, `:177`) | **met** | | Done when — no deploy workflow sends a Semaphore token over http | the job carries no address of its own and the script refuses a non-https one; a workflow case now asserts no `http://`, no `--insecure`, no `SKIP_VERIFY` (`scripts/tests/deploy-workflow.sh:266-268`) | **met** | | Done when — the script headers no longer cite TR-66 STD-2 | neither the base `90fa0ed` nor this head cites TR-66 or STD-2 | **met, vacuously** | | 1 — the TLS listener (cockpit) / 3 — `ci-*` expiry (store) | other repositories | out of scope | No spec findings. The PR body's *What changes* bullet 3 now names `semaphore/service/files/ca.crt`, which is the path cockpit publishes at its head. ## Standards Sources read at the head worktree: `AGENTS.md:7-10` (§Decisions), `AGENTS.md:24-27` (§Code comments), `docs/index.md:12`, `docs/adr/index.md`. ### Round-2 findings, re-driven | # | Round-2 finding | Resolution at `76c839c` | Evidence | | --- | --- | --- | --- | | 1 | the cockpit path named at three sites does not exist | `b886aa9` — `semaphore/service/files/ca.crt` at all three | `scripts/semaphore-deploy.sh:36`, `docs/runbooks/0001-deploy-and-rollback.md:435`, PR body bullet 3. Cockpit at `5a1a37e`: `semaphore/service/files/ca.crt` → 200, `semaphore/tls/ca.crt` → *The target couldn't be found*. Census: `grep -rF 'semaphore/tls/'` over the tree → 0 files. | | 2 | a scheme-less address printed whole, credential included | `7b6e944` — `require_tls` names the scheme only when the string carries one | `scripts/semaphore-deploy.sh:119-124`. Driven: `SEMAPHORE_API_URL='user:hunter2@10.12.0.143:3000'` → `SEMAPHORE_API_URL is an address with no scheme; …`, `hunter2` absent; `http://user:hunter2@…` → `is a http address`, `hunter2` absent; `ftp://…` → `is a ftp address`. Mutant M3 (the scheme-less arm reverted to `${BASE}`) reds exactly the two cases written for it, `scripts/tests/semaphore-deploy.test.sh:225` and `:229`. | | 3 | no record of the pin in `docs/adr/` | `76c839c` — ADR 0010 plus its index row | `docs/adr/0010-the-semaphore-ca-is-committed-beside-the-deploy.md:1-65`, `docs/adr/index.md:18`; `docs-check` reports `adr-index 10 rows and 10 records, the same set both ways`. | **ADVISORY — `scripts/semaphore-deploy.sh:38`, `docs/runbooks/0001-deploy-and-rollback.md:436`, `docs/adr/0010-the-semaphore-ca-is-committed-beside-the-deploy.md:6-7` — three prose enumerations of the pin's options omit one of them.** Each says every Semaphore call carries `--proto '=https'` and `--cacert`. The options the code actually sets are three: `CURL_TLS=(--proto '=https' --tlsv1.2 --cacert "$CA")` at `scripts/semaphore-deploy.sh:126`. The omission is of `--tlsv1.2`, the TLS floor. The sentence is incomplete rather than false — the two named options are the ones the neighbouring claims rest on (no cleartext, and the pinned root) — so this is advice, not a defect: it is the third time a reader meets a list that stops short. Smallest fix: add `--tlsv1.2` to the three lists, or say "carries `--proto '=https'`, a TLS 1.2 floor and `--cacert`". ## Verified - `refs/pull/107/head` = `76c839c069a27914e70a08d9309e48e6b4985e5d`, equal to the dispatch's SHA — `git ls-remote` read when the round opened and again after the mutation wave; both reads agree. - The round's delta is `git diff 8405f40 76c839c`: 5 files, +102/−16, confined to the three clearing changes (ADR + index row, the runbook paragraph, the `require_tls` arm and its two cases). No hunk outside them. - `mise exec -- make check` → **the whole floor green** at this head: `semaphore-deploy tests: every case passed`, `deploy-workflow tests: 71 assertions, 0 FAILED`, `service-key tests: 55 assertions, 0 FAILED`, `verify-stream: 13 passed, 0 failed`, `snapshot tests: every case passed`, `plan workflow tests: every case passed`, `docs-check: all 5 assertions hold`. - The suite can fail, and for the reasons the change claims — three mutants on this worktree, each restored and the blob asserted against `git show HEAD:<path>` before the next: - M1, `require_tls` deleted from `start` → suite **rc=1**. - M2, `--cacert "$CA"` dropped from `CURL_TLS` → suite **rc=1**. - M3, the scheme-less arm reverted to `${BASE}` → suite **rc=1**, and the two named assertions are among the reds. - M4, `--insecure` added to a real step of `deploy.yml` → `deploy-workflow` **rc=1**, `FAIL … it does not skip verification (found [--insecure])`. (A first attempt appended a comment line; `deploy-workflow.sh:76` strips comments before asserting, so that mutant was void and is not counted.) - `require_tls` driven by hand at this head, five inputs: scheme-less with a credential, scheme-less plain, `http://` with a credential, `ftp://` with a credential, and a missing CA file. Each exits 1 before any request, names the scheme or the missing CA, and repeats no credential. - The committed CA is byte-identical to cockpit's at `5a1a37e`: `sha256 5a62c5816adbd382d4bfce8fe1ccb774f7e10173b391abafb90acf2c516fb13a` both sides, and the file served over the forge's contents route is byte-identical to the one in this tree. `openssl x509` on it: `CA:TRUE, pathlen:0`, ECDSA P-256, name-constrained to `10.12.0.143` and `127.0.0.1`. - CI at `76c839c`: the newest status per context is `success` for all eight — `pr-checks` env-check, fmt-check, validate, syntax-check, docs-check; `plan` guest-plan-check, edge-plan-check, runner-guest-plan-check. - `docs/adr/` holds 10 records and `docs/adr/index.md` 10 rows; the ADR's *Consequences* `:47-50` and the runbook's recovery step `:437-442` describe the same procedure in the same order. ## Could not verify - Nothing ran against a live Semaphore or a live forge: `olympus/infra-cockpit#36` is open, so the TLS listener does not exist yet. The trust chain is proved offline only — the pinned CA against cockpit's committed leaf and its committed CA. - The `deploy` job itself has never executed against this tree; it runs on merge, not on the pull request. ## Named, not charged - `scripts/tests/deploy-workflow.sh:55-57` — `assert_contains` pipes a whole file into `grep -qF` under `set -o pipefail` at `:36`, so an early `grep` exit can SIGPIPE `printf` and report a match as missing. The fix round reported this (41 of 300 runs, rc 141, at the base revision). I could not reproduce it: 200 synthetic runs at four haystack sizes from 64 KiB to 4 MiB all returned 0. Pre-existing on a line this diff does not touch; named so it is not read as covered. - `scripts/tests/semaphore-stub.py` `QuietServer.handle_error` swallows every handler exception, not only a refused handshake — new in test code at an earlier round, and no case turns on it. - `scripts/semaphore-deploy.sh:169` — `start_task`'s error path prints `${BASE}` whole. Pre-existing, untouched by this diff; the same class as round-2 finding 2, which fixed the refusal and not this line. - `.forgejo/workflows/deploy.yml` — this round's delta does not touch it. Across the change it is four comment lines, and the four things that define the job — the workflow file, the context names, the job names, and the target each job runs — did not move. Named so a human can overrule that reading. ## Escalation ADR 0010 is a new binding record in a repository, which is an escalation class under the Reviewer charter. Opened as **THE-109** (`status: todo`, `assigneeAgentId` the Board's, `parentId: null`), read back this round after creation. The card's substance: the record's own *Consequences* (`docs/adr/0010-…:51-54`) and *Update when* (`:62`) defer the org-wide record to `olympus/workshop` until "a second repository pins the same file" — and the merge order this PR announces puts `olympus/infra-tracker` in before it does, so the deferral expires on arrival. Per the dispatch, the change's class is not a reason to withhold an approval: the state and label below are the findings', and merging remains the board's gate. Closing: **Standards 1, Spec 0** — 1 finding, 0 blockers. Worst in Standards: the three prose lists that omit `--tlsv1.2` (advisory, one word each). Worst in Spec: none. One advisory is short of the three that would move the recommendation.
pit merged commit e39040946e into main 2026-12-01 15:13:50 +00:00
pit deleted branch hermes/THE-106-semaphore-https 2026-12-01 15:13:50 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
3 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
olympus/infra-forge!107
No description provided.