From c2beefadb42725571ce8b457fa9a54a97e93e70c Mon Sep 17 00:00:00 2001 From: t8simon <104978710+t8simon@users.noreply.github.com> Date: Fri, 6 May 2022 16:13:31 +0200 Subject: [PATCH] moved the REMOTE_AUTH variables into the docker-compose.override.yml example files, as changes to configuration.py would get lost when pulling --- LDAP.md | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/LDAP.md b/LDAP.md index c05d913..0ba7c3d 100644 --- a/LDAP.md +++ b/LDAP.md @@ -6,12 +6,6 @@ LDAP configuration is done by [django ldap module](https://django-auth-ldap.read Take a note that changing `configuration/ldap_config.py` is strongly discouraged. NetBox container reports barely any python errors. -### NetBox v2.9 and above -Netbox 2.9 changes the behaviour for the remote authentication. For LDAP to work these settings are necessary in the `configuration.py` file: -```python -REMOTE_AUTH_ENABLED = True -REMOTE_AUTH_BACKEND = 'netbox.authentication.LDAPBackend' -``` ## Override example @@ -27,6 +21,8 @@ services: netbox: image: &NetboxImage netboxcommunity/netbox:${VERSION-latest-ldap} environment: + REMOTE_AUTH_ENABLED: "True" + REMOTE_AUTH_BACKEND: "netbox.authentication.LDAPBackend" AUTH_LDAP_SERVER_URI: "ldaps://domain.com" AUTH_LDAP_BIND_DN: "CN=Netbox,OU=EmbeddedDevices,OU=MyCompany,DC=domain,dc=com" AUTH_LDAP_BIND_PASSWORD: "TopSecretPassword" @@ -52,6 +48,8 @@ services: netbox: image: &NetboxImage netboxcommunity/netbox:${VERSION-latest-ldap} environment: + REMOTE_AUTH_ENABLED: "True" + REMOTE_AUTH_BACKEND: "netbox.authentication.LDAPBackend" AUTH_LDAP_SERVER_URI: "ldaps://domain.com" AUTH_LDAP_BIND_DN: "cn=netbox,ou=services,dc=domain,dc=com" AUTH_LDAP_BIND_PASSWORD: "TopSecretPassword"