Declare the silo record's own plan key (SL-28) #32
No reviewers
Labels
No labels
needs-info
needs-triage
ready-for-agent
ready-for-human
review
merge-ready
review
needs-fix
review
needs-human
review
needs-operator
review
needs-review
review
waiting
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.
Dependencies
No dependencies set.
Reference
olympus/infra-silo!32
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "hermes/SL-28-the-silo-plan-key-is-declared-its-path-w"
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?
Implements SL-28
Summary
silo/store/variables.tf— one entry invar.state_keys, and the docs that had the plan key as the one exception:tofu-plan-state-siloalready exists in the store and already matchessilo-plan-state-policy.jsoninmake key-audit; what it lacked was a store path for its pair. With that path atsecret/tofu-state/silo/plan(underAWS_ACCESS_KEY_ID/AWS_SECRET_ACCESS_KEY, the backend's own two names), the entry joins the declaration like the other twenty-five and its import adopts the existing key by its bare access key — no second key, no server-generated secret (ADR 0005).The apply key beside it stays the hand mint §0 draws: the Stack reads and writes its state with it, so a key this half declared could not be the key that runs the declaration.
Docs follow: runbook 0003 §7 (25 outside + this one = 26; the path and its two field names; the consumer is SL-30's secret for SL-31's check), ADR 0010 ("the one it does not cover" is now the apply key alone), README, the two state-key headers, runbook 0001's guard count.
Evidence
Before:
mise exec -- make key-mint-testagainstorigin/main's map →not ok tofu-plan-state-silo belongs at secret/tofu-state/silo/plan: … silo/store/variables.tf does not declare 'tofu-plan-state-silo' in var.state_keyskey-mint-test: 1 case(s) failed(exit 2)After: same command →
ok tofu-plan-state-silo belongs at secret/tofu-state/silo/plan,key-mint-test: every case passedmise exec -- make check→ exit 0:env-check: the pin and the map agree.,key-audit-test: every case passed,key-mint-test: every case passed,deploy tests: every case passed.,fmt-checkclean,Success! The configuration is valid.Not run here — the live half, which needs the store's root credential (this repo's agent contract,
docs/agents/workflow.md§3, keeps mutating Targets andmake envoff an agent's floor):secret/tofu-state/silo/planunderAWS_ACCESS_KEY_ID/AWS_SECRET_ACCESS_KEY;mise exec -- make key-mint KEY=tofu-plan-state-silo ACCESS_KEY=<the existing key> SECRET_KEY=<the pair>— the create is skipped because the key exists, and the import adopts it by its bare access key (or runbook 0003 §7 The first import);mise exec -- make store-plan→No changes;MC_HOST_silo=… mise exec -- make key-audit→ 0 failing.The three acceptance criteria on the ticket are these four lines' output; they stay unverified until the Operator runs them from
main.Merge Danger
Door: two-way — the entry only declares;
scripts/store-plan-guard.shmakesmake storerefuse a create on any declared key, so a merge between the merge and the import cannot mint one.Blast Radius: narrow —
silo/store/{variables,state-keys}.tfand four documents. PROD is untouched until the Operator runs the mint/import above.Review started (round 1/5) on
aefc0ee8a1— reading the diff now.Review loop: olympus/infra-silo · PR #32 · reviewed head
dbd1e6bd8e9be86efad06d3918793b91c34f30ba· round 1/5 (no earlier review on the thread) · verdict: APPROVERecommendation: merge
Head note. The dispatch named
aefc0ee8…; the branch took a merge oforigin/main(dbd1e6b, SL-37's runbook 0001 paragraph andsilo/guest/keys.d/semaphore-runner.pub) while I was reading. The author's own change isaefc0eeand is byte-identical in the merged tree:git diff --stat ffdb31d dbd1e6bis the same seven files and 42+/28- as3eeb606..aefc0ee, and the one author hunk in runbook 0001 (twenty-six times, line 173) survived the merge. The checks below were re-run atdbd1e6b. Round 1 ataefc0eeposted no review, so the whole head was reviewed.Spec source: SL-28 (Vikunja project 7, global id 337, the PR body's link), read live. Its build list is: write
secret/tofu-state/silo/plan, declare the entry invar.state_keys, import by the bare access key. Its criteria are: the path reads back with both fields;make store-planreads No changes;make key-auditreports 0 failing with no second key. Blocked-by SL-27 isdone: true.Standard:
AGENTS.md§Rules (Secrets, Code comments), §Docs conventions, anddocs/adr/index.md(one file per decision; reversing one is a new file). Standards sources were read from the head worktree.Standards
docs/adr/index.md:23(ADR 0010's summary row: "The other Stacks' state keys are declared…"),README.md:141-142(the new sentence says "declared with the rest", the next sentence says "The other Stacks' state keys are declared"), anddocs/runbooks/0003-the-state-in-the-store.md:257(the §7 heading "The other Stacks' keys", which now also covers the silo plan key). Fix in one clause per site; the §7 heading's anchor is linked from0003:21and0003:175, so reword the summary and the README and leave the heading alone, or move the links with it. This is one finding with three sites.README.md:129: "the plan key beside it is the plan check's, a repository secret and never.env". SL-30 (the repository secrets) and SL-31 (the check) are bothdone: falseon the tracker.docs/runbooks/0003-the-state-in-the-store.md:275-276says it correctly in the future tense ("this repository gains — SL-30 lands the secret, SL-31 the check") but its first clause, "That path is a repository secret", calls a store path a repository secret (the secret is SL-30's copy of what is at the path). One finding, two sites: put the README row in the same future tense and make the runbook clause "the repository secret SL-30 sets is a copy of what is at that path".Not charged (precedent in the repo): the five-line comment at
silo/store/variables.tf:108-112againstAGENTS.md§Code comments. Its neighbours (variables.tf:61-63,:74-76,:93-95,:103-106) carry comments of the same size and the same ticket pointers, so this is the file's own reading of the rule. The ADR 0010 edit (docs/adr/0010-…md:15-26) is an amendment under a standing decision;git logon that file shows SL-24, SL-27 and SL-26 each amended it the same way, sodocs/adr/index.md:26("a new file … not an edit of the record") governs reversals and does not apply.Spec
No findings. Verified against the ticket:
silo/store/variables.tf:112addstofu-plan-state-silowithsilo-plan-state-policy.json, which exists. The map now holds 26 entries (counted bysed/grep; matches the "twenty-six" the ADR, runbook 0003 §7 and runbook 0001 now say). The comment's reach claim (readsprod/silo.tfstate, writes only the lock) matchessilo/store/silo-plan-state-policy.json.secret/tofu-state/silo/planis whatmake key-mintderives for the key, and the case is in the test table (scripts/tests/key-mint.test.sh:325).#the-first-importanchor at0003:600); the mint's exists-path case (key-mint.test.sh, "a key that already exists is adopted, not refused") is the existing generic coverage of that path.scripts/store-plan-guard.shfed a plan whose only change is acreateonmodule.store.minio_iam_service_account.state_key["tofu-plan-state-silo"]exits 1 and names the address; ano-opexits 0.Verified by hand (head
dbd1e6b, ls-remote equal before and after)make checkexit 0mise exec -- make checkkey-audit-test,key-mint-testand deploy tests all "every case passed";fmt-checkandvalidateclean3eeb606not ok tofu-plan-state-silo belongs at secret/tofu-state/silo/plan … does not declare 'tofu-plan-state-silo',1 case(s) failed(the new case fails without the entry)ok tofu-plan-state-silo belongs at …, every case passedvar.state_keysentries andsilo/store/*policy.jsonprovisioner-policy.json+state-policy.json)Could not verify
docs/agents/workflow.md§3 keeps it off an agent's floor): thattofu-plan-state-siloexists in the store, that its parent issilo-admin(the owner ADR 0010 binds a declared key to), that the pair atsecret/tofu-state/silo/planreads back with both fields, thatmake store-planreads No changes after the import, and thatmake key-auditreports 0 failing. These are the ticket's three acceptance criteria and stay open until the Operator runs them; the ticket is not closable from this merge alone.Summary
docs/adr/index.md:23,README.md:141-142,0003:257)No blockers. Two advisories sit under the three-advisory line, so the recommendation is merge and both travel as advice.