fix: sops global to relative path

This commit is contained in:
Adrian Gunnar Lauterer 2024-11-16 15:06:45 +01:00
parent 6cdcafb03d
commit 910cd3316b
1 changed files with 15 additions and 14 deletions

View File

@ -10,21 +10,22 @@
# This will add secrets.yml to the nix store # This will add secrets.yml to the nix store
# You can avoid this by adding a string to the full path instead, i.e. # You can avoid this by adding a string to the full path instead, i.e.
# sops.defaultSopsFile = "/root/.sops/secrets/example.yaml"; # sops.defaultSopsFile = "/root/.sops/secrets/example.yaml";
sops.defaultSopsFile = "/etc/nixos/nix-dotfiles/secrets/secrets.yaml"; # sops.defaultSopsFile = "/etc/nixos/nix-dotfiles/secrets/secrets.yaml";
sops.validateSopsFiles = false; sops = {
# This will automaticx-sopsally import SSH keys as age keys defaultSopsFile = ../secrets/secrets.yaml;
sops.age.sshKeyPaths = [ validateSopsFiles = false;
# This will automaticx-sopsally import SSH keys as age keys
age.sshKeyPaths = [
"/etc/ssh/nixos" "/etc/ssh/nixos"
"/root/.ssh/nixos" "/root/.ssh/nixos"
#"/$HOME/.ssh/nixos"
#"/home/gunalx/.ssh/nixos"
]; ];
# This is using an age key that is expected to already be in the filesystem # This is using an age key that is expected to already be in the filesystem
sops.age.keyFile = "/var/lib/sops-nix/key.txt"; #age.keyFile = "/var/lib/sops-nix/key.txt";
# This will generate a new key if the key specified above does not exist age.keyFile = "/root/.config/sops/age/key.txt";
sops.age.generateKey = true; # This will generate a new key if the key specified above does not exist
age.generateKey = true;
# This is the actual specification of the secrets. # This is the actual specification of the secrets.
#sops.secrets."myservice/my_subdir/my_secret" = {}; #secrets."myservice/my_subdir/my_secret" = {};
};
} }