diff --git a/cabot/settings.py b/cabot/settings.py index c3b6406..932aa2d 100644 --- a/cabot/settings.py +++ b/cabot/settings.py @@ -246,9 +246,10 @@ REST_FRAMEWORK = { AUTHENTICATION_BACKENDS = ( 'django.contrib.auth.backends.ModelBackend', ) -AUTH_LDAP = os.environ.get('AUTH_LDAP', 'false') -if AUTH_LDAP.lower() == "true": +AUTH_LDAP = os.environ.get('AUTH_LDAP', False) + +if AUTH_LDAP: from settings_ldap import * AUTHENTICATION_BACKENDS += tuple(['django_auth_ldap.backend.LDAPBackend'])