Repository navigation
feat(skein): add the weave and selvage role passwords - #50
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
On skein (
patchwork_central, prod), the rolesweaveandselvagehad no password, so no app could log in ("no password file for weave; it cannot log in yet").secrets/central-prod-weave.ageandsecrets/central-prod-selvage.age. Each holds a random 64-hex password, encrypted tojspandskein. Nobody saw the values./run/central-db/patchwork_central/<app>, owned bypostgres, andcentral-db-setupsets each role password. This is the same setup as seam.central-db-setupruns again when a password file changes.No app uses skein yet. When an app connects, add the host that runs it as a recipient, and put the same password in that app's env file.
Deploy
deploy .#skein. This deploy also makes skein tailnet only (#48). Postgres does not restart. Onlycentral-db-setupruns.Known limits
These come from the review. Both are in
modules/central-dbfrom before this change, and both apply to seam too:central-db-setuppasses the password topsqlas an argument. A local user on skein can see it in/procfor a moment. IfALTER ROLEfails, the statement goes to the journal.ALTER ROLE ... PASSWORD NULLby hand.Test plan
nixosConfigurations.skeinevaluates.age.secretshascentral-prod-weaveandcentral-prod-selvageat/run/central-db/patchwork_central/, owned bypostgres.central-staging-*only.journalctl -u central-db-setuphas no "no password file" line. Inpg_authid,weaveandselvagehave a password.