authelia: add support for redis

This commit is contained in:
eyjhb 2025-03-02 16:23:34 +01:00
parent dd5a97ce13
commit 300efecc13
Signed by: eyjhb
GPG key ID: 609F508E3239F920

View file

@ -34,6 +34,10 @@ in {
authelia_url = "https://${svc_domain}";
} ];
# setup redis for sessions, otherwise it's in-memory, and everyone
# has to login again each time authelia is restarted
session.redis.host = "${config.services.redis.servers.authelia.unixSocket}";
server.address = "tcp://127.0.0.1:${builtins.toString port}";
# totp - disable for now, as it requires email server
@ -89,6 +93,13 @@ in {
};
};
# setup redis for persisting session
# across reboots
services.redis.servers.authelia = {
enable = true;
user = authelia_user;
};
# setup lldap user for authelia that can send emails
services.lldap.provision.users = config.mine.shared.lib.ldap.mkScope (lconfig: llib: {
authelia = llib.mkProvisionUserSystem "authelia" config.age.secrets.authelia-smtp-password.path;