deploy-archive: the erseco image's first-boot install never completes — the #1254 readiness gate correctly waits out 300 s twice and fails loud, so the red is the install itself, not the race #1255
Labels
No labels
agent-blocked
agent-working
autopilot
bug
deferred
deploy-pending
enhancement
landing-pr
model-haiku
model-opus
model-sonnet
needs-design
needs-info
needs-triage
no-triage
out-of-scope
priority
ready-for-agent
ready-for-human
ready-for-session
rehearsal-183
snapshot-pending
standing-drive
wayfinder:grilling
wayfinder:map
wayfinder:prototype
wayfinder:research
wayfinder:task
wontfix
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Reference
Matou/idss#1255
Loading…
Add table
Add a link
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?
The failure
Drive
20260906T044617Z(commit4b88d9d6, the #1254 readiness gate), 6/7 green, red atdeploy-archiveafter 1 119 287 ms:The #1254 gate is not the defect — it did its job.
logs/guest-omeka-reconcile.log, with the podman event noise stripped, is one line of reconciler output:That is
internal/clan/archive.go:503-506firing the loud ceiling exactly asTestRenderArchive_ReconcilerReadinessGate(internal/clan/archive_test.go:302) pins it, and GOTCHAS #175 prescribes.The evidence that the race is over and the install is the fault
logs/guest-omeka-reconcile.log: 97container exec/ 98container exec_diedevents spanning05:13:50→05:19:37— the full 100-try poll ofinternal/clan/archive.go:492-502. Every one failed with an install-not-ready string;readywas never set.fc244322a7b2on every event.podman-omeka.servicenever restarted during the wait, so the image's entrypoint never re-attempted its install.05:13:40(first switch) and05:19:41(clean-retry);logs/guest-unit.logrecordsConsumed 12.984s CPU time over 5min 58.061s wall clockfor the last invocation. On the second switch the container had already been up ≥ 6 minutes before the poll started, and the CLI's answer was stillOmeka S is not installed.20260906T035418Z) seeing the answer progressdatabase.ini doesn't exist→Omeka S is not installed.within 4 s. Twelve minutes later, run 12 gets the same second answer. An install in flight changes its answer; this one is parked.logs/guest-failed-units.log: onlyomeka-reconcile.servicefailed.podman-omeka.serviceandpodman-omeka-db.serviceare both fine — the container process is up andomeka-s-cliexecs cleanly. The app is running; Omeka is simply not installed in it.logs/guest-archive-keystore.log:NOT-MINTED— consistent, the mint is downstream of the gate.Do NOT raise the 300 s ceiling. That is the cheap wrong fix and this run's evidence rules it out: ~12 minutes across two switches, one never-restarted container, 98 identical answers.
Suspected layer
The erseco image's first-boot install, one layer below the #175 fault — the same class, applied to the container rather than the reconciler.
Leading hypothesis:
internal/clan/archive.go:322gives the Omeka containerdependsOn = [ "omeka-db" ]. Likeafter/requiresin #175, that is start-ordering, not readiness:podman-omeka-db.servicereachingactiveproves the MariaDB process started, not that it accepts connections. On a cold boot MariaDB initialises its datadir on the freshly-tmpfiles-created/var/lib/archive/db(internal/clan/archive.go:353-357), which takes tens of seconds. If the erseco entrypoint runs its install once and does not retry, it ran against a DB refusing connections, failed, and the container has served an uninstalled Omeka ever since — matching the never-restarted container id and the frozen CLI answer. That the image got as far as writingdatabase.ini(run 11) is consistent:database.iniis written from env before the installer runs.Alternatives not yet excluded:
OMEKA_MODULES = "LocalContexts"(internal/clan/archive.go:315) — the image fetches the module on start; a failed or hanging fetch over the guest's SLIRP network could stop the entrypoint before the installer.DB_HOST = "omeka-db"(internal/clan/archive.go:308) not resolving on thearchivepodman network (aardvark-dns), so every install attempt fails at connect.The evidence gap that blocks the call
All three hypotheses are settled by one artifact that is not harvested: the Omeka container's own log.
guestCollectors(app/tests/e2e/fixtures/evidence.ts:327-400) captures the reconciler journal (:384) and the keystore (:393) — added by #1243 — but nothing runspodman logs omekaorpodman logs omeka-db. Every future red here is undiagnosable at the same cost.Secondary gap:
logs/clan-config-snapshot.logpoints at the host'sstate/clan-config(mtime05:00,HEAD 468cb63, founding-ceremony commits only). It contains nomachines/gateway/archive.nixand novars/per-machine/gateway/archive-secrets, yet both containers came up with the generator's env file read — so the deploy ran from the guest's config repo, which nothing harvests. Worth confirming rather than assuming, but the snapshot as collected says nothing about the failing deploy.Suggested work
guest-omeka-app/guest-omeka-dbcollectors (podman logs --tail 200 omeka/omeka-db) toguestCollectorsbesideapp/tests/e2e/fixtures/evidence.ts:384, and freeze the names inapp/tests/e2e/fixtures/evidence.test.ts:233. Land this first — it is what names the cause.dependsOn— thehealthWaitprecedent GOTCHAS #175 already names (internal/clan/idssidp.go:207-215,internal/clan/keri.go:339) — and/or make the first-boot install re-attempt. Keep the #1254 gate and its 300 s ceiling as-is; it is the check that surfaced this honestly.Why this was refused rather than healed
Refusal rule 3 (product-behaviour surface). The fix lands in
renderOmekaContainers/renderArchiveStore(internal/clan/archive.go:295-358) — the NixOS module the switch applies. Changing how the archive port's containers start is what a deploy does, not harness or fixture plumbing; #1247 and #1254 both went through a ruling (ADR 0174) for the same reason.Compounding: without
podman logs omekathe cause is three live hypotheses, so any edit would be a guess dressed as a heal — and the two cheap guesses available in-lane (raise the ceiling; soften the gate) are precisely the ones this run's evidence forbids.Advances #1235.
drive
20260906T044617Zred atdeploy-archive:deploy failed (clean-retry): provision: deploy gateway: clan: deploy failed on 1 node(s): gateway: clan: masked_exit on gateway: clan reported success but the log shows a real failure: the remote switevidence:
/home/swarm/swarm/Matou/idss/test-results/private-path/20260906T044617Zon matou-workstation (legs.json and whatever else the drive harvested there) — a representative screenshot is attached here if one was capturedRuling — REPRODUCED LOCALLY, root cause found, two-way door (ADR 0174),
ready-for-agentI ran the port's two containers on the laptop with docker, byte-identical images (
erseco/alpine-omeka-s@sha256:fb2522…,mariadb:11.4) and byte-identical env torenderOmekaContainers(DB_HOST/DB_NAME/DB_USER/DB_PORT, OMEKA_ADMIN_EMAIL, OMEKA_SITE_TITLE, OMEKA_TIMEZONE, OMEKA_MODULES=LocalContexts, the env file with DB_PASSWORD/MARIADB_*/OMEKA_ADMIN_PASSWORD). Deterministic, three runs.Root cause: the image's install is skipped silently because we never set
OMEKA_ADMIN_NAMEThe pinned digest's entrypoint (
/docker-entrypoint-init.d/02-configure-omeka.sh, quoted from inside the container):The upstream README says
OMEKA_ADMIN_NAME"defaults to Site Administrator". The pinned bits do not. With our env the container's own stdout is:No "Installing Omeka S via CLI…" line at all; nginx + fpm then start and serve an uninstalled Omeka forever. That is exactly the drive's picture: one container id,
podman-omeka.serviceactive,database.inipresent,core:status=not_installedfor 12 minutes, the #1254 gate correctly timing out. The healer's DB-readiness hypothesis is ruled out — the entrypointnc-waits onomeka-db:3306with no ceiling BEFORE writingdatabase.ini, and run 11 sawdatabase.iniappear.With
OMEKA_ADMIN_NAMEset (fresh DB):Installing Omeka S via CLI... Installation completed.→Module 'LocalContexts' successfully installed.→core:status=installed,module:listshows LocalContextsactive.Surprise 2 (#1213's deferred mint stdout shape) — ALSO confirmed, and it is the NEXT red as written
omeka-s-cli user:create-api-key <email> <label>(v0.14.0) prints a text table, not identity/credential lines:renderOmekaReconcile's parse (sed -n 's/.*[Ii]dentity[^0-9A-Za-z]*\([0-9A-Za-z]\{8,\}\).*/\1/p'and the[Cc]redentialtwin) matches NOTHING in that output — the word "identity" never appears, and the "Key Credential" header is followed by "Key", not a token — so after the install fix the reconciler would fail loud withcould not parse the minted API key. Proven shape that DOES work:--json:(
key_idis what Omeka's API callskey_identityin its query params;key_credentialis the secret.) Also proven: a second mint with the SAME label →API key with label '…' already existsrc 255 — the store-presence early exit is what keeps the reconciler idempotent, so keep it first (it is) and note the hazard: a lost store with a live key would need the label to move (mint with a timestamped label is the cheap escape; ruling = keep the fixed label, document the hazard in GOTCHAS, do not engineer around it now).module:enableon an already-enabled module →Module 'LocalContexts' is already enabled.rc 0 — the #1254 classifier's ready path is correct.Fix (one ticket — same script, and the parse red is a CERTAIN next red I have the bytes for; this saves a full 65-min cycle)
internal/clan/archive.gorenderOmekaContainers: addOMEKA_ADMIN_NAMEto the omeka container'senvironment(a constant, e.g."Community archive admin"— no new config surface; comment that the pinned digest has NO default and returns silently without it). Pin it in the render test next toOMEKA_ADMIN_EMAIL(a render that drops it must red — this is a cannot-fail-class input: ask what the container does ON THE FAILURE PATH when a var is missing — it does nothing, silently).renderOmekaReconcile: mint with--jsonand parsekey_id/key_credentialfrom it (jq is fine —${pkgs.jq}/bin/jq -r .key_id; or a sed pinned to the two JSON keys). Keep the loudcould not parseexit. Store staysidentity\ncredential(key_id then key_credential) soarchivehealth.goreads unchanged — verifyArchiveAdmin.Keyconsumption expects identity=key_id as thekey_identityquery param. Update the verb allowlist test only if it asserts the exact argv (the verbuser:create-api-keyis unchanged;--jsonis a flag).app/tests/e2e/fixtures/evidence.ts): nothing captures the container's OWN stdout, which is where this defect announced itself in plain text (ERROR: Failed to install modules) while both the healer and I were blind. Addguest-omeka-container=journalctl -u podman-omeka -u podman-omeka-db --no-pager -n 300(NixOS oci-containers log to the journal under the unit) next toguest-omeka-reconcile. Cheap, same file, same shape as its siblings.user:create-api-keyprints a table, use--json; (c) same-label re-mint is rc 255 — the store IS the idempotency key.Hazard to note, not to build: Omeka's installer validates the admin email's TLD against a known list (
.test/.localare rejected:'example.test' is not a valid hostname for the email address), and on that failure the entrypoint EXITS (the unit would restart-loop). Our defaultadmin@archive.<apex>underidss.nzpasses; a non-public apex would not. The new collector (3) makes that failure visible if it ever happens.Expected after landing: run 13 deploy-archive green (install completes in the image's first boot, ~30 s after the DB is ready; the #1254 gate rides that out),
guest-archive-keystore.log= MINTED (two 32-char lines), thenarchive-healthyruns the real keep→serve→refuse loop for the first time.swarm-claim host=elitebook-distributed-server-03 run=18780
(automated multi-host claim — lowest live claim id works this ticket)
close-report for #1255 — status
success✅ close-report gates passed — every claim verified against main; issue closed.
envelope
admin@archive.<apex>— under the private path's.idss.internalapex (ADR 0149) Omeka's installer rejects the TLD, aborts the first-boot install half-done, and no admin user ever exists #1274grampsweb-adminswallows its own failure with|| true, sowhakapapa-brand403s on every token POST and reds the switch at exit 4 #1311module:enablewent "ready" three seconds before Omeka's installer created the admin user, so the key mint died onUser not foundand starved archive-brand #1320