nixos-config/hosts/nuc/modules/authentik/default.nix

24 lines
586 B
Nix
Raw Normal View History

2024-05-20 12:19:05 +02:00
{ config, ... }:
let
domain = "auth.${config.networking.domain}";
in
{
2024-05-23 09:25:08 +02:00
age.secrets.authentik-core = {
file = ../../../../secrets/nuc/authentik/core.age;
};
age.secrets.authentik-ldap = {
file = ../../../../secrets/nuc/authentik/ldap.age;
2024-05-20 12:19:05 +02:00
};
services.authentik = {
enable = true;
2024-05-23 09:25:08 +02:00
environmentFile = config.age.secrets.authentik-core.path;
};
services.authentik-ldap = {
enable = true;
environmentFile = config.age.secrets.authentik-ldap.path;
2024-05-20 12:19:05 +02:00
};
2024-05-21 18:44:04 +02:00
services.caddy.virtualHosts."${domain}".extraConfig = ''
reverse_proxy localhost:9000
'';
2024-05-20 12:19:05 +02:00
}