docs(install): revise for sops-provisioned identities (task 0012) #6
Reference in New Issue
Block a user
Delete Branch "task-0012-secrets-operations-docs"
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?
Task:
.claude/tasks/0012-secrets-operations-docs.mdSummary
docs/install.mdwas built around a login password set by hand throughnixos-enterafter the install. That step no longer exists now that the password arrives as a decrypted secret, so the parts of the document describing it were wrong rather than merely incomplete. This is a revision rather than an appendix.The document is retitled "Installing and provisioning a host" and given a table of contents, since three of its four procedures are not installs.
Deviations
Redundancy between the install and recovery sections (the disko remount block, the re-key sequence) is deliberate rather than an oversight. An operator running the recovery procedure is locked out of the machine, so sending them to page back into the install steps mid-recovery costs more than maintaining two copies. The already-running-host procedure does cross-reference, because that reader has a working machine.
The recovery procedure is documented but unexercised — running it means deliberately locking out the only machine. Both branches follow from verified facts:
nixos-installis idempotent and reuses the formatted disk, and the secrets file is baked into the closure at build time, which is why one branch needs a rebuild and the other does not.Commands were verified against the running system rather than written from memory:
sops updatekeys,age-keygen -y, andnixos-install --root/--flake/--no-root-passwordwere each confirmed to exist, and the identity file's0400 root:rootat/var/lib/sops-nix/key.txtwas read off the live machine.Review
Risk
Overall: HIGH
passwdescape hatch is removed from the text./dev/nvme0n1on the only machine in the fleet.Findings
All Standards and Spec findings were addressed in the diff. Four factual errors the Spec axis caught are worth recording, since each would have misled an operator:
ls -l /run/secrets/, butneededForUsersputs the password hash in/run/secrets-for-users/(confirmed bynix eval). The one secret whose failure causes the lockout the document exists to prevent was the one the reader was told not to look at..sops.yamlexample registered a new host against the shared rule but added no rule for the host's own file, which makessopsrefuse it withno matching creation rules found.updatekeysomittedSOPS_AGE_KEY_FILE, so it would have looked in~/.config/sops/age/keys.txtrather than the root-owned identity.ssh-host-<type>-keyentries, without which the build fails at evaluation.One follow-up is left open rather than fixed: task 0019 adds user SSH keys, which will make "no authorized SSH key" in the no-fallback paragraph stale. That paragraph is the place to revisit when it lands.