vars: don't use sops.secrets.*.restartUnits on macOS
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
{
|
||||
_class,
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
@@ -42,20 +43,23 @@ in
|
||||
secrets = lib.listToAttrs (
|
||||
map (secret: {
|
||||
name = "vars/${secret.generator}/${secret.name}";
|
||||
value = {
|
||||
inherit (secret)
|
||||
owner
|
||||
group
|
||||
mode
|
||||
neededForUsers
|
||||
restartUnits
|
||||
;
|
||||
sopsFile = builtins.path {
|
||||
name = "${secret.generator}_${secret.name}";
|
||||
path = secretPath secret;
|
||||
};
|
||||
format = "binary";
|
||||
};
|
||||
value =
|
||||
{
|
||||
inherit (secret)
|
||||
owner
|
||||
group
|
||||
mode
|
||||
neededForUsers
|
||||
;
|
||||
sopsFile = builtins.path {
|
||||
name = "${secret.generator}_${secret.name}";
|
||||
path = secretPath secret;
|
||||
};
|
||||
format = "binary";
|
||||
}
|
||||
// (lib.optionalAttrs (_class == "nixos") {
|
||||
inherit (secret) restartUnits;
|
||||
});
|
||||
}) (builtins.filter (x: builtins.pathExists (secretPath x)) vars)
|
||||
);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user