Overcomplicated agenix setup done!
This commit is contained in:
parent
a7a0869dbe
commit
1c125ab3b2
4 changed files with 17 additions and 13 deletions
|
@ -3,13 +3,16 @@
|
|||
inputs,
|
||||
lib,
|
||||
...
|
||||
}: let
|
||||
secretsPath = ../../secrets;
|
||||
in {
|
||||
}: {
|
||||
environment.systemPackages = [inputs.agenix.packages.x86_64-linux.default]; # TODO: USE WRAPPER
|
||||
|
||||
age.secrets = lib.listToAttrs (map (name: _: {
|
||||
name = name;
|
||||
value.file = "${secretsPath}/${name}";
|
||||
}) (lib.filter (name: lib.hasSuffix ".age" name) (dirUtils.dirFiles secretsPath)));
|
||||
age = {
|
||||
identityPaths = [
|
||||
"/home/quadradical/.ssh/id_ed25519"
|
||||
];
|
||||
secrets = lib.listToAttrs (map (path: {
|
||||
name = lib.last (builtins.split "/" (toString path));
|
||||
value.file = path;
|
||||
}) (dirUtils.dirFiles ".age" ../../secrets));
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue