make ldap username attribute configurable

This commit is contained in:
Pay Giesselmann
2023-08-29 09:30:57 +02:00
parent 81d9015d59
commit fd94d30a8e
4 changed files with 22 additions and 7 deletions

View File

@@ -15,6 +15,7 @@ type LdapConfig struct {
SearchDN string `json:"search_dn"`
UserBind string `json:"user_bind"`
UserFilter string `json:"user_filter"`
UserAttr string `json:"username_attr"`
SyncInterval string `json:"sync_interval"` // Parsed using time.ParseDuration.
SyncDelOldUsers bool `json:"sync_del_old_users"`

View File

@@ -180,6 +180,10 @@
"description": "Filter to extract users for syncing.",
"type": "string"
},
"username_attr": {
"description": "Attribute with full username. Default: gecos",
"type": "string"
},
"sync_interval": {
"description": "Interval used for syncing local user table with LDAP directory. Parsed using time.ParseDuration.",
"type": "string"