standing/activation: every device drive burns an LE order — rehearsal-d's apex is walled #987

Closed
opened 2026-08-29 12:31:07 +00:00 by matou-build-agent · 2 comments

The failure

verdict.json reds with firstRedLeg: "standing" (15 green / 2 red / 0 skip). standing is the umbrella prefix leg (1 737 713 ms — the whole run); the leg that actually threw is activation (626 987 ms), and both carry the same message from legs.json:

"the gateway deploy failed — The gateway deploy failed. [There is no old operating system to roll back to — this server was rented fresh for the community, so nothing of yours was overwritten.]"

The gateway box itself is healthy. logs/gateway-units.txt shows systemctl --failed empty, and caddy, control-plane, kanidmd, netbird-mgmt/signal, coturn and acme-dns all listening (*:443, *:8080, 127.0.0.1:8443, …). What failed is the one thing the deploy waits on: the apex front door never answered over TLS.

logs/founding-state.log opens the wait on two doors and then names only one for the next 119 probes:

"waiting for the public front doors [id.rehearsal-d.idss.nz rehearsal-d.idss.nz] to answer over TLS — acme-dns registration + DNS-01 issuance gate Caddy's :443 on a first boot, and the apex is a separate order that can lag the wildcard's (#499, #524)"

"[rehearsal-d.idss.nz] not answering yet (probe 119/120) — re-probing in 5s (Caddy still gated behind acme-dns registration / issuance, #499, #524)"

id.rehearsal-d.idss.nz drops out after the opening line — the wildcard order issued fine, so acme-dns and DNS-01 both work. Only the apex's separate order is stuck, and logs/gateway-caddy.txt says exactly why, on all five obtain attempts:

caddy[3068]: {"level":"error","logger":"tls.obtain","msg":"could not get certificate from issuer","identifier":"rehearsal-d.idss.nz","error":"HTTP 429 urn:ietf:params:acme:error:rateLimited - too many certificates (5) already issued for this exact set of identifiers in the last 168h0m0s, retry after 2026-08-30 01:35:49 UTC"}"

The 429 lands at new-order — the challenge was never reached. Let's Encrypt's duplicate-certificate cap for the exact identifier set rehearsal-d.idss.nz is spent, and Caddy's backoff had reached "retrying_in":600 by elapsed:627.5 when the probe budget (120 × 5 s) ran out.

The cap is spent because the drive re-founds on a fixed slug and never persists the cert it earned. Every re-drive against rehearsal-d starts a fresh gateway with an empty /var/lib/caddy, so every drive spends a fresh apex order plus a fresh wildcard order.

Suspected layer — the drive harness, not the product

The product behaved correctly given a walled CA: Caddy retried with proper backoff, id. served, the deploy reported a failure rather than a false green. The rate limit is an infra fact; the reason the drive keeps hitting it is harness wiring.

This run directory shows the cert-persistence worker never ran on the device target: logs/ contains no cert-rented.txt (the reap verdict file) and no caddy-rented.txt, while it does carry every other harvest (gateway-caddy.txt, gateway-units.txt, gateway-stall.txt, gateway-do-forensics.txt, …).

The rehearsal healer that ran at 12:27 (logs/healer-claude.out, commit 39d16e7e) fixed the reporting half only — internal/founding/deploy.go now classifies the 429 as kind: "rate_limited" instead of shipping the cold-start story this run rendered:

founding-state.log → "failure": {"kind": "unknown", "headline": "The gateway deploy failed.", "detail": "https://rehearsal-d.idss.nz did not answer over TLS within the first-boot cold-start budget … resume the deploy to re-probe once it settles"} — advice that could not have worked before 2026-08-30 01:14 UTC, offered alongside a Resume the deploy button.

That commit explicitly hands back the substantive fault: the drive still burns an order per run. Its harness citations (scripts/smoke-private-path.sh:602 arming oc_rented_certs_arm only for target == rented; test-results/cert-store/ holding a rehearsal-c dir but no rehearsal-d; the rent-operator key living under the standing community's state dir rather than the run dir) are unverified here — this session is confined to the run directory and reads outside it were denied. They need confirming before anyone edits those lines.

What plugging it needs

  1. Arm the cert-persistence worker on the device target's re-found path, so a drive that rents a fresh gateway against the fixed slug seeds Caddy's store from the last run and harvests it after. A device drive against an already-standing community rents nothing and must stay untouched.
  2. Before wiring it, resolve where the worker reads the rent-operator SSH identity from — the device drive's run dir has artifacts/droplet-ip.txt (134.199.155.189) but the key appears to live under the standing community's state dir. If it silently fails to authenticate, the worker degrades to a note while orders keep burning.
  3. Consider folding the apex into the wildcard's SAN set. It halves orders per drive and removes the "apex is a separate order that can lag" hazard (#524, GOTCHAS #15) that this probe copy is written around — but that is a product change and wants a ruling.
  4. Cover the device arm in the offline harness test, and amend GOTCHAS #32, whose #724 note still names rented as the standing queue's target.

Unblocking now: rehearsal-d is walled until ~2026-08-30 01:14–01:37 UTC (the retry-after instant drifts across the five attempts as the 168 h window slides). Rotating REHEARSAL_SLUG unblocks a re-drive but still spends idss.nz's registered-domain new-orders budget at ~2 orders per drive — and burns the next slug the same way until this is landed.

Absent / not consulted

  • No live-box section was appended to this brief, so nothing was asked of either machine directly. Both were still up when the harness harvested at 12:19–12:20 (gateway-do-forensics.txt: tcp/22: a FRESH connect succeeded), and those snapshots — systemctl --failed, ss -tlnp, the caddy issuer log — are what a live session would have asked for anyway, so the diagnosis does not depend on shell access.
  • No logs/droplet-journal.txt as named in the brief; the journal is split into gateway-journal.txt (2 029 lines) and device-journal.txt (1 351 lines).
  • logs/broker-journal.txt is a harvest failure by design: "dev@100.98.48.68: Permission denied (publickey)" — off the admin mesh (ADR 0208, #681); the verdict does not depend on it.
  • This is not the known frontier. legs.json carries no skip reasons at all (skip: 0), and pair is green at 126 ms. The own-VPS carrier issue named as this drive's known red is not what reds here — the drive never reached the device-add legs, so the device box 170.64.182.214 is untouched stock Ubuntu (device-units.txt: only sshd and systemd-resolved listening), which is expected, not a second fault.
  • One cosmetic race worth noting but not causal: gateway-caddy.txt:2 — acme-dns-register-start[2340]: curl: (7) Failed to connect to 127.0.0.1 port 8081 after 0 ms at 12:03:48, with the unit reporting Finished at 12:03:50 and acme-dns binding 127.0.0.1:8081 at 12:03:49. It retried and won; the wildcard's successful issuance proves the registration path is sound.

drive 20260829T114921Z red at activation: the gateway deploy failed — The gateway deploy failed. [There is no old operating system to roll back to — this server was rented fresh for the community, so nothing of yours was overwritten.]
evidence: /home/swarm/swarm/Matou/idss/test-results/drive-device/20260829T114921Z on matou-workstation (legs.json and whatever else the drive harvested there) — a representative screenshot is attached here if one was captured

## The failure `verdict.json` reds with `firstRedLeg: "standing"` (15 green / 2 red / **0 skip**). `standing` is the umbrella prefix leg (1 737 713 ms — the whole run); the leg that actually threw is **`activation`** (626 987 ms), and both carry the same message from `legs.json`: > `"the gateway deploy failed — The gateway deploy failed. [There is no old operating system to roll back to — this server was rented fresh for the community, so nothing of yours was overwritten.]"` The gateway box itself is healthy. `logs/gateway-units.txt` shows `systemctl --failed` **empty**, and caddy, control-plane, kanidmd, netbird-mgmt/signal, coturn and acme-dns all listening (`*:443`, `*:8080`, `127.0.0.1:8443`, …). What failed is the one thing the deploy waits on: the **apex** front door never answered over TLS. `logs/founding-state.log` opens the wait on two doors and then names only one for the next 119 probes: > `"waiting for the public front doors [id.rehearsal-d.idss.nz rehearsal-d.idss.nz] to answer over TLS — acme-dns registration + DNS-01 issuance gate Caddy's :443 on a first boot, and the apex is a separate order that can lag the wildcard's (#499, #524)"` > > `"[rehearsal-d.idss.nz] not answering yet (probe 119/120) — re-probing in 5s (Caddy still gated behind acme-dns registration / issuance, #499, #524)"` `id.rehearsal-d.idss.nz` drops out after the opening line — the **wildcard order issued fine**, so acme-dns and DNS-01 both work. Only the apex's separate order is stuck, and `logs/gateway-caddy.txt` says exactly why, on all five obtain attempts: > `caddy[3068]: {"level":"error","logger":"tls.obtain","msg":"could not get certificate from issuer","identifier":"rehearsal-d.idss.nz","error":"HTTP 429 urn:ietf:params:acme:error:rateLimited - too many certificates (5) already issued for this exact set of identifiers in the last 168h0m0s, retry after 2026-08-30 01:35:49 UTC"}"` The 429 lands at **new-order** — the challenge was never reached. Let's Encrypt's duplicate-certificate cap for the exact identifier set `rehearsal-d.idss.nz` is spent, and Caddy's backoff had reached `"retrying_in":600` by `elapsed:627.5` when the probe budget (120 × 5 s) ran out. The cap is spent because **the drive re-founds on a fixed slug and never persists the cert it earned**. Every re-drive against `rehearsal-d` starts a fresh gateway with an empty `/var/lib/caddy`, so every drive spends a fresh apex order plus a fresh wildcard order. ## Suspected layer — the drive harness, not the product The product behaved correctly given a walled CA: Caddy retried with proper backoff, `id.` served, the deploy reported a failure rather than a false green. The rate limit is an infra fact; the reason the drive keeps hitting it is harness wiring. This run directory shows the cert-persistence worker never ran on the `device` target: `logs/` contains **no `cert-rented.txt`** (the reap verdict file) and **no `caddy-rented.txt`**, while it does carry every other harvest (`gateway-caddy.txt`, `gateway-units.txt`, `gateway-stall.txt`, `gateway-do-forensics.txt`, …). The rehearsal healer that ran at 12:27 (`logs/healer-claude.out`, commit `39d16e7e`) fixed the **reporting** half only — `internal/founding/deploy.go` now classifies the 429 as `kind: "rate_limited"` instead of shipping the cold-start story this run rendered: > `founding-state.log` → `"failure": {"kind": "unknown", "headline": "The gateway deploy failed.", "detail": "https://rehearsal-d.idss.nz did not answer over TLS within the first-boot cold-start budget … resume the deploy to re-probe once it settles"}` — advice that could not have worked before 2026-08-30 01:14 UTC, offered alongside a `Resume the deploy` button. That commit explicitly hands back the substantive fault: the drive still burns an order per run. Its harness citations (`scripts/smoke-private-path.sh:602` arming `oc_rented_certs_arm` only for `target == rented`; `test-results/cert-store/` holding a `rehearsal-c` dir but no `rehearsal-d`; the rent-operator key living under the standing community's state dir rather than the run dir) are **unverified here** — this session is confined to the run directory and reads outside it were denied. They need confirming before anyone edits those lines. ## What plugging it needs 1. Arm the cert-persistence worker on the `device` target's re-found path, so a drive that rents a fresh gateway against the fixed slug seeds Caddy's store from the last run and harvests it after. A device drive against an already-standing community rents nothing and must stay untouched. 2. Before wiring it, resolve where the worker reads the rent-operator SSH identity from — the device drive's run dir has `artifacts/droplet-ip.txt` (`134.199.155.189`) but the key appears to live under the standing community's state dir. If it silently fails to authenticate, the worker degrades to a note while orders keep burning. 3. Consider folding the apex into the wildcard's SAN set. It halves orders per drive and removes the "apex is a separate order that can lag" hazard (#524, GOTCHAS #15) that this probe copy is written around — but that is a product change and wants a ruling. 4. Cover the device arm in the offline harness test, and amend GOTCHAS #32, whose #724 note still names `rented` as the standing queue's target. **Unblocking now:** `rehearsal-d` is walled until ~2026-08-30 01:14–01:37 UTC (the retry-after instant drifts across the five attempts as the 168 h window slides). Rotating `REHEARSAL_SLUG` unblocks a re-drive but still spends idss.nz's registered-domain new-orders budget at ~2 orders per drive — and burns the next slug the same way until this is landed. ## Absent / not consulted - **No live-box section was appended to this brief**, so nothing was asked of either machine directly. Both were still up when the harness harvested at 12:19–12:20 (`gateway-do-forensics.txt`: `tcp/22: a FRESH connect succeeded`), and those snapshots — `systemctl --failed`, `ss -tlnp`, the caddy issuer log — are what a live session would have asked for anyway, so the diagnosis does not depend on shell access. - No `logs/droplet-journal.txt` as named in the brief; the journal is split into `gateway-journal.txt` (2 029 lines) and `device-journal.txt` (1 351 lines). - `logs/broker-journal.txt` is a harvest failure by design: `"dev@100.98.48.68: Permission denied (publickey)"` — off the admin mesh (ADR 0208, #681); the verdict does not depend on it. - **This is not the known frontier.** `legs.json` carries no skip reasons at all (`skip: 0`), and `pair` is **green at 126 ms**. The own-VPS carrier issue named as this drive's known red is not what reds here — the drive never reached the device-add legs, so the device box `170.64.182.214` is untouched stock Ubuntu (`device-units.txt`: only `sshd` and `systemd-resolved` listening), which is expected, not a second fault. - One cosmetic race worth noting but not causal: `gateway-caddy.txt:2` — `acme-dns-register-start[2340]: curl: (7) Failed to connect to 127.0.0.1 port 8081 after 0 ms` at 12:03:48, with the unit reporting `Finished` at 12:03:50 and acme-dns binding `127.0.0.1:8081` at 12:03:49. It retried and won; the wildcard's successful issuance proves the registration path is sound. drive `20260829T114921Z` red at `activation`: `the gateway deploy failed — The gateway deploy failed. [There is no old operating system to roll back to — this server was rented fresh for the community, so nothing of yours was overwritten.]` evidence: `/home/swarm/swarm/Matou/idss/test-results/drive-device/20260829T114921Z` on matou-workstation (legs.json and whatever else the drive harvested there) — a representative screenshot is attached here if one was captured <!-- rehearsal-sig: 4c82deb1e678 -->
Author
Member

swarm-claim host=elitebook-distributed-server-03 run=13828
(automated multi-host claim — lowest live claim id works this ticket)

swarm-claim host=elitebook-distributed-server-03 run=13828 (automated multi-host claim — lowest live claim id works this ticket)
Author
Member

close-report for #987 — status success

✅ close-report gates passed — every claim verified against main; issue closed.

envelope
{
  "issue": 987,
  "status": "success",
  "commits": [
    "baa3fe7a86b199a2bde7e48bb443ef51ab9cba75"
  ],
  "changed_files": [
    "scripts/lib/rehearsal-droplet.sh",
    "scripts/smoke-private-path.sh",
    "scripts/tests/rehearsal-rented-certs-test.sh",
    "scripts/tests/rehearsal-device-target-test.sh",
    "docs/GOTCHAS.md"
  ],
  "tests": [
    {
      "command": "bash scripts/tests/rehearsal-rented-certs-test.sh",
      "exit_code": 0
    },
    {
      "command": "bash scripts/tests/rehearsal-device-target-test.sh",
      "exit_code": 0
    },
    {
      "command": "bash scripts/tests/droplet-evidence-order-test.sh",
      "exit_code": 0
    },
    {
      "command": "bash -n scripts/smoke-private-path.sh scripts/lib/rehearsal-droplet.sh",
      "exit_code": 0
    }
  ],
  "criteria": {
    "Arm the cert-persistence worker on the device target's re-found path (rents a fresh gateway); an adopt drive stays untouched": "scripts/smoke-private-path.sh: new arm gated on target==device AND OC_STANDING_REFOUND==1, before the drive; rehearsal-device-target-test.sh case 14 pins the wiring/gate/ordering",
    "Resolve where the worker reads the rent-operator SSH identity from (standing home, not run dir)": "scripts/lib/rehearsal-droplet.sh: oc_rented_certs_arm/oc_rented_certs_worker take an identity-home 8th arg (default $run_dir/state); device arm passes $OC_STANDING_DIR/state; rehearsal-rented-certs-test.sh case 20 proves the worker dials with the identity home's key, not $run_dir/state",
    "Cover the device arm in the offline harness test": "rehearsal-device-target-test.sh case 14 (source-level arm assertion) + rehearsal-rented-certs-test.sh case 20 (identity threading), both pass",
    "Amend GOTCHAS #32, whose #724 note still names rented as the standing queue's target": "docs/GOTCHAS.md #32: added 'Amended (#987)' paragraph recording the device re-found gap, the fix, and the identity-home wrinkle",
    "Fold apex into wildcard SAN (product change, wants a ruling)": "OUT OF SCOPE — noted as an open product option in GOTCHAS #32; not implemented (a product change needing a ruling per the issue)"
  },
  "summary": "The device re-found path now arms the cert-persistence worker with the standing home's rent-operator identity, so a fresh gateway seeds from the last drive's store instead of burning a fresh Let's Encrypt order.",
  "blockers": []
}
**close-report** for #987 — status `success` :white_check_mark: **close-report gates passed** — every claim verified against main; issue closed. <details><summary>envelope</summary> ```json { "issue": 987, "status": "success", "commits": [ "baa3fe7a86b199a2bde7e48bb443ef51ab9cba75" ], "changed_files": [ "scripts/lib/rehearsal-droplet.sh", "scripts/smoke-private-path.sh", "scripts/tests/rehearsal-rented-certs-test.sh", "scripts/tests/rehearsal-device-target-test.sh", "docs/GOTCHAS.md" ], "tests": [ { "command": "bash scripts/tests/rehearsal-rented-certs-test.sh", "exit_code": 0 }, { "command": "bash scripts/tests/rehearsal-device-target-test.sh", "exit_code": 0 }, { "command": "bash scripts/tests/droplet-evidence-order-test.sh", "exit_code": 0 }, { "command": "bash -n scripts/smoke-private-path.sh scripts/lib/rehearsal-droplet.sh", "exit_code": 0 } ], "criteria": { "Arm the cert-persistence worker on the device target's re-found path (rents a fresh gateway); an adopt drive stays untouched": "scripts/smoke-private-path.sh: new arm gated on target==device AND OC_STANDING_REFOUND==1, before the drive; rehearsal-device-target-test.sh case 14 pins the wiring/gate/ordering", "Resolve where the worker reads the rent-operator SSH identity from (standing home, not run dir)": "scripts/lib/rehearsal-droplet.sh: oc_rented_certs_arm/oc_rented_certs_worker take an identity-home 8th arg (default $run_dir/state); device arm passes $OC_STANDING_DIR/state; rehearsal-rented-certs-test.sh case 20 proves the worker dials with the identity home's key, not $run_dir/state", "Cover the device arm in the offline harness test": "rehearsal-device-target-test.sh case 14 (source-level arm assertion) + rehearsal-rented-certs-test.sh case 20 (identity threading), both pass", "Amend GOTCHAS #32, whose #724 note still names rented as the standing queue's target": "docs/GOTCHAS.md #32: added 'Amended (#987)' paragraph recording the device re-found gap, the fix, and the identity-home wrinkle", "Fold apex into wildcard SAN (product change, wants a ruling)": "OUT OF SCOPE — noted as an open product option in GOTCHAS #32; not implemented (a product change needing a ruling per the issue)" }, "summary": "The device re-found path now arms the cert-persistence worker with the standing home's rent-operator identity, so a fresh gateway seeds from the last drive's store instead of burning a fresh Let's Encrypt order.", "blockers": [] } ``` </details>
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
Matou/idss#987
No description provided.