split waybar into multiple files
This commit is contained in:
parent
53c7532351
commit
7cff7f09c3
29 changed files with 953 additions and 617 deletions
18
sops.nix
18
sops.nix
|
|
@ -11,10 +11,15 @@ let
|
|||
adminKeys = [
|
||||
"0D98D5964AC8BB1CA034CE4EC456133700066642" # xyno main gpg key
|
||||
];
|
||||
keysPerHost = (mapAttrs (n: v: (toList v.sopsKey)) (
|
||||
filterAttrs (n: v: v ? sopsKey) instanceConfigs
|
||||
));
|
||||
keysPerHost = (
|
||||
mapAttrs (n: v: (toList v.sopsKey)) (filterAttrs (n: v: v ? sopsKey) instanceConfigs)
|
||||
);
|
||||
desktopHostNames = [ "theseus" ];
|
||||
|
||||
hostKeys = flatten (attrValues keysPerHost);
|
||||
desktopKeys = flatten (
|
||||
attrValues (filterAttrs (n: v: any (x: x == n) desktopHostNames) keysPerHost)
|
||||
);
|
||||
|
||||
sopsCfg = {
|
||||
keys = adminKeys ++ hostKeys;
|
||||
|
|
@ -23,6 +28,10 @@ let
|
|||
path_regex = "secrets/[^/]+\.(yaml|json|env|ini)$";
|
||||
key_groups = [ { pgp = adminKeys ++ hostKeys; } ];
|
||||
}
|
||||
{
|
||||
path_regex = "secrets/desktop/[^/]+\.(yaml|json|env|ini)$";
|
||||
key_groups = [ { pgp = adminKeys ++ desktopKeys; } ];
|
||||
}
|
||||
]
|
||||
++ (mapAttrsToList (n: v: {
|
||||
# path_regex = "instances/${n}/secrets/[^/]+\.(yaml|json|env|ini)$";
|
||||
|
|
@ -33,4 +42,5 @@ let
|
|||
};
|
||||
sopsCfgFile = writeText ".sops.yaml" (builtins.toJSON sopsCfg);
|
||||
|
||||
in sopsCfgFile
|
||||
in
|
||||
sopsCfgFile
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue