mirror of
https://github.com/Superredstone/nixos.git
synced 2026-03-07 12:28:02 +01:00
434 B
434 B
Secrets
Add a new machine
- Obtain an age identity
nix run nixpkgs#ssh-to-age -- \
-private-key \
-i /etc/ssh/ssh_host_ed25519_key \
-o $HOME/.config/sops/age/keys.txt
- Obtain age recipient for the machine
cat /etc/ssh/ssh_host_ed25519_key.pub | nix run nixpkgs#ssh-to-age
- Paste obtained key into
.sops.yaml - Re-encrypt old files
sops updatekeys secrets/default.sops.yaml