My configs ... but in Nix!
nix run .#deployNixosLocal -- '<config name>'
nix run .#deployNixDarwin -- '<config name>'
nix run .#deployHomeManagerLocal -- '<config name>'
On first deploy, you may need to update your shell
nix run .#homeManagerUseFish
Requires access to the admin ssh key
nix run .#deployNixosRemote -- '<config name>' '<ip>'
Sops-nix is used for managing secrets.
Secrets are encrypted and stored in secrets/secrets.yaml
. Only users with keys
in a key group can access secrets. Key group are declared in .sops.yaml
.
Note: these commands currently use the 1password CLI to fetch the sops encryption key.
Prerequisites:
- Age keypair
1. Update .sops.yaml
- Add the keypair's public key to the
keys
section of file - Add a reference to the key in the
age
key group
2. Re-encrypt secrets/secrets.yaml
with the new key groups
nix run .#secretsSync
nix run .#secretsEdit
nix run .#secretsRotate
nix run .#saveAdminKeys
This will save a local copy of:
- admin SSH key: needed to deploy to remotes
- server (age) key: needed on all systems to access sops secrets
This requires a local copy of the admin SSH key and the server key.
nix run .#distributeAdminKeys -- '<ip>'
nix fmt
nix eval .#packages.aarch64-darwin --apply builtins.attrNames