Some REMOTE_AUTH_ settings missing
Desired Behavior
I'd like to be able to provide all the Remote Auth settings as environment variables.
Contrast to Current Behavior
Currently only
REMOTE_AUTH_ENABLED
REMOTE_AUTH_BACKEND
REMOTE_AUTH_HEADER
REMOTE_AUTH_AUTO_CREATE_USER
REMOTE_AUTH_DEFAULT_GROUPS
are able to be pulled in from environment variables
Required Changes
Adding the ability to declare the other environment variables.
Discussion: Benefits and Drawbacks
I'm aware that I can do it currently by adding an extra file to the configuration folder but it would be good to not have to mount an extra file into the container.
Also aware that REMOTE_AUTH_DEFAULT_PERMISSIONS isn't recommended due to the complexity of the value - ref https://github.com/netbox-community/netbox-docker/issues/890 - but that shouldn't preclude the other variables from being made available.
We cannot set up Azure AD (Tenants), the user ends up getting redirected to the Azure auth server with client_id=None set in the query parameters
This seems to be caused by this issue. The SOCIAL_AUTH_AZUREAD_TENANT_OAUTH2_KEY (AzureAD App ID) variable is set but seemingly not being forwarded to Netbox
could be related to #653
We are having this issue as well
Was able to fix by adding the following to configuration.py:
SOCIAL_AUTH_AZUREAD_TENANT_OAUTH2_KEY = environ.get('SOCIAL_AUTH_AZUREAD_TENANT_OAUTH2_KEY', '')
SOCIAL_AUTH_AZUREAD_TENANT_OAUTH2_SECRET = environ.get('SOCIAL_AUTH_AZUREAD_TENANT_OAUTH2_SECRET', '')
SOCIAL_AUTH_AZUREAD_TENANT_OAUTH2_TENANT_ID = environ.get('SOCIAL_AUTH_AZUREAD_TENANT_OAUTH2_TENANT_ID', '')
Of course, you'll need to add whichever one you're using, I am using tenant.
I just opened a PR that adds the missing config options #1144