mirror of
https://github.com/Mic92/sops-nix.git
synced 2025-03-05 16:17:47 +00:00
Merge #316
316: HM: make `secretsMountPoint` and `symlinkPath` configurable r=Mic92 a=Shawn8901 Co-authored-by: MidAutumnMoon <me@418.im>
This commit is contained in:
commit
5698b06b07
1 changed files with 20 additions and 3 deletions
|
@ -25,7 +25,7 @@ let
|
|||
|
||||
path = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
default = "%r/secrets/${name}";
|
||||
default = "${cfg.defaultSymlinkPath}/${name}";
|
||||
description = ''
|
||||
Path where secrets are symlinked to.
|
||||
If the default is kept no other symlink is created.
|
||||
|
@ -66,8 +66,8 @@ let
|
|||
name = "manifest${suffix}.json";
|
||||
text = builtins.toJSON {
|
||||
secrets = builtins.attrValues secrets;
|
||||
secretsMountPoint = "%r/secrets.d";
|
||||
symlinkPath = "%r/secrets";
|
||||
secretsMountPoint = cfg.defaultSecretsMountPoint;
|
||||
symlinkPath = cfg.defaultSymlinkPath;
|
||||
keepGenerations = cfg.keepGenerations;
|
||||
gnupgHome = cfg.gnupg.home;
|
||||
sshKeyPaths = cfg.gnupg.sshKeyPaths;
|
||||
|
@ -133,6 +133,23 @@ in {
|
|||
'';
|
||||
};
|
||||
|
||||
defaultSymlinkPath = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
default = "%r/secrets";
|
||||
description = ''
|
||||
Default place where the latest generation of decrypt secrets
|
||||
can be found.
|
||||
'';
|
||||
};
|
||||
|
||||
defaultSecretsMountPoint = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
default = "%r/secrets.d";
|
||||
description = ''
|
||||
Default place where generations of decrypted secrets are stored.
|
||||
'';
|
||||
};
|
||||
|
||||
keepGenerations = lib.mkOption {
|
||||
type = lib.types.ints.unsigned;
|
||||
default = 1;
|
||||
|
|
Loading…
Add table
Reference in a new issue