Skip to content

Commit

Permalink
django-allowed-hosts fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
javierdelapuente committed May 20, 2024
1 parent 45d5bef commit 87e724c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
2 changes: 1 addition & 1 deletion charm/tests/integration/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,7 @@ async def netbox_app_fixture(
resources=resources,
config={
"django-debug": False,
"django-allowed-hosts": '["*"]',
"django-allowed-hosts": '*',
"aws-endpoint-url": s3_netbox_configuration["endpoint"],
},
)
Expand Down
5 changes: 1 addition & 4 deletions netbox/netbox/configuration.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,7 @@
# This is a list of valid fully-qualified domain names (FQDNs) for the NetBox server. NetBox will not permit write
# access to the server via any other hostnames. The first FQDN in the list will be treated as the preferred name.
#

# The double prefix DJANGO_DJANGO is probably related to discrepancies between the charmcraft version
# and the paas-app-charmer version. Wait until charmcraft is merged in main to report.
ALLOWED_HOSTS = json.loads(os.environ.get("DJANGO_DJANGO_ALLOWED_HOSTS", "[]"))
ALLOWED_HOSTS = json.loads(os.environ.get("DJANGO_ALLOWED_HOSTS", "[]"))

# PostgreSQL database configuration. See the Django documentation for a complete list of available parameters:
# https://docs.djangoproject.com/en/stable/ref/settings/#databases
Expand Down

0 comments on commit 87e724c

Please sign in to comment.