vars: implement sops.defaultGroups

This commit is contained in:
DavHau
2024-07-11 18:39:00 +07:00
parent 7055b352d4
commit 9988fb744c
6 changed files with 50 additions and 57 deletions

View File

@@ -33,15 +33,6 @@ let
secrets = filterDir containsMachineOrGroups secretsDir;
in
{
options = {
clan.core.sops.defaultGroups = lib.mkOption {
type = lib.types.listOf lib.types.str;
default = [ ];
example = [ "admins" ];
description = "The default groups to for encryption use when no groups are specified.";
};
};
config = lib.mkIf (config.clan.core.facts.secretStore == "sops") {
# Before we generate a secret we cannot know the path yet, so we need to set it to an empty string
clan.core.facts.secretPathFunction =