diff --git a/modules/nixos/tasks/backup-archive/default.nix b/modules/nixos/tasks/backup-archive/default.nix index ee3d0ba6..29b828d0 100644 --- a/modules/nixos/tasks/backup-archive/default.nix +++ b/modules/nixos/tasks/backup-archive/default.nix @@ -42,13 +42,14 @@ in { config = lib.mkIf cfg.enable { sops.secrets = let + borgSecretsPath = key: "borg-backup/${key}"; getKey = key: { inherit key; sopsFile = lib.getSecret "backup-archive.yaml"; - name = "borg-backup/${key}"; + name = borgSecretsPath key; }; getSecrets = keys: - lib.listToAttrs (lib.lists.map (key: lib.nameValuePair key (getKey key)) keys); + lib.listToAttrs (lib.lists.map (key: lib.nameValuePair (borgSecretsPath key) (getKey key)) keys); in getSecrets [ "borg-patterns/home" "borg-patterns/etc"