added sops for all three systems

This commit is contained in:
Gerg-L 2023-03-06 23:10:58 -05:00
parent 1742726d84
commit e6f83f6997
13 changed files with 207 additions and 28 deletions

22
modules/sops.nix Normal file
View file

@ -0,0 +1,22 @@
{sops-nix, ...}: {
pkgs,
settings,
self,
config,
...
}: {
imports = [
sops-nix.nixosModules.sops
];
environment.systemPackages = [
pkgs.sops
];
sops = {
defaultSopsFile = "${self}/systems/${config.networking.hostName}/secrets.yaml";
age = {
sshKeyPaths = ["/home/${settings.username}/.ssh/id_ed25519"];
keyFile = "/home/${settings.username}/.config/sops/age/keys.txt";
generateKey = true;
};
};
}