Files
nix-config/modules/home/sops/default.nix
mjallen18 d76eff6f68 cleanup
2025-12-12 13:39:40 -06:00

29 lines
529 B
Nix

{
config,
lib,
namespace,
...
}:
let
cfg = config.${namespace}.sops;
in
{
imports = [ ./options.nix ];
config = {
sops = {
age.keyFile = "/home/${config.${namespace}.user.name}/.config/sops/age/keys.txt";
defaultSopsFile = "/etc/nixos/secrets/secrets.yaml";
validateSopsFiles = false;
secrets = {
"github-token" = { };
};
templates = {
".env".content = ''
GITHUB_TOKEN = "${config.sops.placeholder.github-token}"
'';
};
};
};
}