2024-06-05 12:30:55 +01:00
|
|
|
{ inputs, config, ... }:
|
2024-05-12 19:58:55 +01:00
|
|
|
let
|
2024-05-14 14:51:09 +01:00
|
|
|
secretsDirectory = builtins.toString inputs.nix-secrets;
|
|
|
|
secretsFile = "${secretsDirectory}/secrets.yaml";
|
2024-05-12 19:58:55 +01:00
|
|
|
homeDirectory = config.home.homeDirectory;
|
2024-05-17 20:17:53 +01:00
|
|
|
username = config.home.username;
|
2024-05-12 19:58:55 +01:00
|
|
|
in
|
|
|
|
{
|
|
|
|
imports = [
|
|
|
|
inputs.sops-nix.homeManagerModules.sops
|
|
|
|
];
|
|
|
|
|
|
|
|
sops = {
|
2024-06-05 12:30:55 +01:00
|
|
|
age = {
|
|
|
|
sshKeyPaths = [ "${homeDirectory}/.ssh/id_ed25519" ];
|
|
|
|
generateKey = true;
|
|
|
|
keyFile = "/home/${username}/.config/sops/age/keys.txt";
|
|
|
|
};
|
2024-05-12 19:58:55 +01:00
|
|
|
defaultSopsFile = "${secretsFile}";
|
|
|
|
validateSopsFiles = false;
|
2024-06-05 12:30:55 +01:00
|
|
|
|
|
|
|
secrets = {
|
|
|
|
"ssh_keys/deploy_key/id_ed25519" = {
|
|
|
|
path = "/home/${username}/.ssh/deploy_key-ssh-ed25519";
|
|
|
|
};
|
|
|
|
};
|
2024-05-12 19:58:55 +01:00
|
|
|
};
|
|
|
|
}
|