Repository navigation
fix(clan): migrate clan machine path off removed clanModules (#159) #3684
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| c5e451b2d6c22070 | ||
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
On deployment, this preserves the old network ID without migrating the controller identity from
sops/secrets/user-zerotier-identity-secret/secretinto the new vars store. A newly generated identity cannot control this network: ZeroTier's protocol documentation specifies that the first 10 hex digits of a network ID identify its controller, so this network requires the identityc5e451b2d6. Being both controller and peer does not allow a different identity to authorize itself on that network. Import the existing controller identity before generating/deploying the new service; preserving identities alongside network IDs is also required by the Clan migration guide.Useful? React with 👍 / 👎.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Accepted — verified, not merging past this.
Verified on the PR head (6306477):
vars/per-machine/user/contains only disk-id, openssh, and state-version — there is no zerotier identity in the vars store, while the controller identity exists only atsops/secrets/user-zerotier-identity-secret. The PR preserves the network ID (vars/shared/zerotier-network-zerotier/network-id/value) without importing that identity, so a deploy-time vars generation would mint a new controller identity that cannot authorize peers on this network (network-ID prefix = controller identity, per the linked ZeroTier doc and the Clan zerotier migration guide).Disposition: merge of PR #3684 is blocked on this finding. Fix path (queue task 2943, parked with this as the resume condition): import the existing controller identity from the sops secret into the zerotier service's vars before any deploy, per the Clan migration guide — a deliberate secrets-handling step, not done in a shift tail. Alternative if the import proves impractical: split the zerotier instance out of this PR and re-verify eval. The rest of the PR is verified:
nix eval .#nixosConfigurations.user.config.system.build.toplevel.drvPathpasses at head and no clanModules refs remain in modules/*.nix.