feat: massive refactoring...

This commit is contained in:
Xavier Morel
2025-11-09 00:45:00 +01:00
parent f9446df46d
commit 3245b6b89f
77 changed files with 3233 additions and 582 deletions

30
config/auth-authentik.nix Normal file
View File

@@ -0,0 +1,30 @@
{ tools, config, ... }:
let
hostname = tools.build_hostname "auth";
in
{
# Doesn't seem to like having the path directly in the params below?!
environment.etc = {
"authentik/ldap-secrets.env".source = config.age.secrets.auth-authentik-ldap-secrets.path;
"authentik/proxy-secrets.env".source = config.age.secrets.auth-authentik-proxy-secrets.path;
"authentik/secrets.env".source = config.age.secrets.auth-authentik-secrets.path;
};
services = {
authentik = {
enable = true;
environmentFile = "/etc/authentik/secrets.env";
nginx = {
enable = true;
host = hostname;
};
};
authentik-ldap = {
enable = true;
environmentFile = "/etc/authentik/ldap-secrets.env";
};
authentik-proxy = {
enable = true;
environmentFile = "/etc/authentik/proxy-secrets.env";
};
};
}