From 9f4a9f528ce7163e8ebaa73963d6e5308a7aad9a Mon Sep 17 00:00:00 2001 From: Alex Houlton Date: Mon, 19 Oct 2020 07:50:33 -0700 Subject: [PATCH] add option to mirror ldap groups into netbox this commit allows ldap assigned groups to be mirrored into netbox users. The default is None as this is not the primary way to do this change. --- configuration/ldap_config.py | 1 + 1 file changed, 1 insertion(+) diff --git a/configuration/ldap_config.py b/configuration/ldap_config.py index 19277e1..23a1e6d 100644 --- a/configuration/ldap_config.py +++ b/configuration/ldap_config.py @@ -71,6 +71,7 @@ AUTH_LDAP_USER_FLAGS_BY_GROUP = { # For more granular permissions, we can map LDAP groups to Django groups. AUTH_LDAP_FIND_GROUP_PERMS = os.environ.get('AUTH_LDAP_FIND_GROUP_PERMS', 'True').lower() == 'true' +AUTH_LDAP_MIRROR_GROUPS = os.environ.get('AUTH_LDAP_MIRROR_GROUPS', None).lower() == 'true' # Cache groups for one hour to reduce LDAP traffic AUTH_LDAP_CACHE_TIMEOUT = int(os.environ.get('AUTH_LDAP_CACHE_TIMEOUT', 3600))