add all hosts to sops
This commit is contained in:
parent
7478e0268a
commit
b260b29a85
6 changed files with 73 additions and 12 deletions
modules/shared
12
modules/shared/sops-nix.nix
Normal file
12
modules/shared/sops-nix.nix
Normal file
|
@ -0,0 +1,12 @@
|
|||
{
|
||||
config,
|
||||
inputs,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
let
|
||||
defaultSopsPath = "${inputs.self}/hosts/${config.networking.hostName}/secrets.yaml";
|
||||
in
|
||||
{
|
||||
sops.defaultSopsFile = lib.mkIf (builtins.pathExists defaultSopsPath) defaultSopsPath;
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue