summaryrefslogtreecommitdiff
path: root/modules/nixos/sops.nix
blob: 41e828e4d4f40d78f8806251057aaffdb8ed99c0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
{config, ... }: {
  # This will add secrets.yml to the nix store
  # You can avoid this by adding a string to the full path instead, i.e.
  # sops.defaultSopsFile = "/root/.sops/secrets/example.yaml";
  sops.defaultSopsFile = ../../secrets/example.yaml;
  # This will automatically import SSH keys as age keys
  sops.age.sshKeyPaths = [ "/etc/ssh/ssh_host_ed25519_key" ];
  # This is using an age key that is expected to already be in the filesystem
  sops.age.keyFile = "/var/lib/sops-nix/key.txt";
  # This will generate a new key if the key specified above does not exist
  sops.age.generateKey = true;
  # This is the actual specification of the secrets.
  # sops.secrets.example-key = {};
  # sops.secrets.example_array = {};
}