1

System/Servenix+Thinknix: Fix sops key issue, they key location assumed an impermanent setup

Changed the default location to /home/${username}/.secrets/age/age.key,
impermanent systems have to override this.
This commit is contained in:
2025-07-25 23:33:48 +02:00
parent e677a74c41
commit 3c93a7e549
3 changed files with 5 additions and 5 deletions

View File

@ -91,8 +91,6 @@ with mylib.networking; {
polkit.enable = true; polkit.enable = true;
# TODO: This does not work on ServeNix?
# Check on ThinkNix...
sops-nix.bootSecrets.${username} = [ sops-nix.bootSecrets.${username} = [
"user-password" "user-password"
]; ];

View File

@ -26,9 +26,7 @@ in {
defaultSopsFile = ./secrets.yaml; defaultSopsFile = ./secrets.yaml;
age = { age = {
# NOTE: Sops needs the keys before impermanence kicks in keyFile = lib.mkDefault "/home/${username}/.secrets/age/age.key";
# so we have to link to /persist directly...
keyFile = "/persist/home/${username}/.secrets/age/age.key";
generateKey = false; generateKey = false;
sshKeyPaths = []; sshKeyPaths = [];
}; };

View File

@ -85,6 +85,10 @@
]; ];
}; };
# NOTE: Sops needs the keys before impermanence kicks in
# so we have to link to /persist directly...
sops.age.keyFile = "/persist/home/${username}/.secrets/age/age.key";
sops.templates."makemkv-settings.conf" = { sops.templates."makemkv-settings.conf" = {
owner = config.users.users.${username}.name; owner = config.users.users.${username}.name;
content = '' content = ''