Split sops keys into root and normal user

Deploy sops keys using Colmena
This commit is contained in:
Pim Kunis 2024-11-17 22:31:57 +01:00
parent 85b41d6722
commit 46a99bf13d
6 changed files with 56 additions and 21 deletions

View file

@ -18,6 +18,22 @@ inputs @ {
deployment = {
allowLocalDeployment = true;
targetHost = null;
keys = {
root-sops-age-key = {
keyCommand = ["sudo" "nix" "run" "nixpkgs#sops" "--" "--extract" "[\"sops_age_key\"]" "-d" "${self}/machines/sue/nixos.sops.yaml"];
name = "keys.txt";
destDir = "/root/.config/sops/age";
};
pim-sops-age-key = {
keyCommand = ["sudo" "nix" "run" "nixpkgs#sops" "--" "--extract" "[\"sops_age_key\"]" "-d" "${self}/machines/sue/home.sops.yaml"];
name = "keys.txt";
destDir = "/home/pim/.config/sops/age";
user = "pim";
group = "users";
};
};
};
imports = [