fix(agenix-rekey-default)!: use lib.mkDefault
This commit is contained in:
parent
70d949e7e0
commit
b8f75023b2
2 changed files with 6 additions and 6 deletions
|
@ -17,9 +17,9 @@
|
||||||
|
|
||||||
age.rekey = {
|
age.rekey = {
|
||||||
hostPubkey = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPopSTZ81UyKp9JSljCLp+Syk51zacjh9fLteqxQ6/aB";
|
hostPubkey = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPopSTZ81UyKp9JSljCLp+Syk51zacjh9fLteqxQ6/aB";
|
||||||
masterIdentities = [ "${inputs.self}/secrets/privkey.age" ];
|
# masterIdentities = [ "${inputs.self}/secrets/privkey.age" ];
|
||||||
storageMode = "derivation";
|
# storageMode = "local";
|
||||||
# forceRekeyOnSystem = "aarch64-linux";
|
# localStorageDir = "${inputs.self}/secrets/rekeyed/${config.networking.hostName}";
|
||||||
};
|
};
|
||||||
|
|
||||||
nixpkgs = {
|
nixpkgs = {
|
||||||
|
|
|
@ -6,9 +6,9 @@ in {
|
||||||
# TODO: cleaner deep check
|
# TODO: cleaner deep check
|
||||||
config = lib.mkIf (lib.all lib.id [(builtins.hasAttr "age" options) (builtins.hasAttr "rekey" options.age)]) {
|
config = lib.mkIf (lib.all lib.id [(builtins.hasAttr "age" options) (builtins.hasAttr "rekey" options.age)]) {
|
||||||
age.rekey = lib.mkIf (config.age.rekey.hostPubkey != dummyPubkey) {
|
age.rekey = lib.mkIf (config.age.rekey.hostPubkey != dummyPubkey) {
|
||||||
masterIdentities = [ "${inputs.self}/secrets/privkey.age" ];
|
masterIdentities = lib.mkDefault [ "${inputs.self}/secrets/privkey.age" ];
|
||||||
storageMode = "local";
|
storageMode = lib.mkDefault "local";
|
||||||
localStorageDir = "${inputs.self}/secrets/rekeyed/${config.networking.hostName}";
|
localStorageDir = lib.mkDefault "${inputs.self}/secrets/rekeyed/${config.networking.hostName}";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue