fix lldap config
This commit is contained in:
parent
4e1bcd6425
commit
9d0061fe6b
1 changed files with 13 additions and 4 deletions
|
|
@ -3,10 +3,13 @@
|
|||
in {
|
||||
age.secrets = {
|
||||
"hidden_service/lldap".file = ../secrets/hidden_service/lldap;
|
||||
"lldap_root_pass".file = ../secrets/lldap_root_pass;
|
||||
}
|
||||
"lldap_root_pass" = {
|
||||
file = ../secrets/lldap_root_pass;
|
||||
mode = "0440";
|
||||
group = "lldap-secrets";
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
services.lldap = {
|
||||
enable = true;
|
||||
settings = {
|
||||
|
|
@ -16,7 +19,7 @@ in {
|
|||
ldap_user_dn = "root";
|
||||
ldap_base_dn = "dc=distrust,dc=network";
|
||||
ldap_user_pass_file = config.age.secrets."lldap_root_pass".path;
|
||||
force_ldap_user_pass_reset = true;
|
||||
force_ldap_user_pass_reset = "always";
|
||||
};
|
||||
};
|
||||
|
||||
|
|
@ -36,4 +39,10 @@ in {
|
|||
];
|
||||
};
|
||||
};
|
||||
|
||||
# Creates a group for the LLDAP DynamicUser to read the secret
|
||||
users.groups.lldap-secrets = {};
|
||||
systemd.services.lldap.serviceConfig = {
|
||||
SupplementaryGroups = [ "lldap-secrets" ];
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue