6
0
mirror of https://github.com/ChristianLight/tutor.git synced 2024-09-28 12:19:02 +00:00

Remove useless ALLOWED_HOSTS values

The port number is not included in the hostname when checking the list
of allowed values.
We also add the "lms"/"cms" values for interaction with the API from
within the internal docker network.
This commit is contained in:
Régis Behmo 2019-07-07 13:48:22 +08:00
parent 90650b691a
commit 45a573d8e5
2 changed files with 2 additions and 7 deletions

View File

@ -7,13 +7,10 @@ execfile(os.path.join(os.path.dirname(__file__), "common.py"), globals())
ALLOWED_HOSTS = [ ALLOWED_HOSTS = [
ENV_TOKENS.get("CMS_BASE"), ENV_TOKENS.get("CMS_BASE"),
"cms",
"127.0.0.1", "127.0.0.1",
"localhost", "localhost",
"studio.localhost", "studio.localhost",
"127.0.0.1:8000",
"localhost:8000",
"127.0.0.1:8001",
"localhost:8001",
] ]
DEFAULT_FROM_EMAIL = ENV_TOKENS["CONTACT_EMAIL"] DEFAULT_FROM_EMAIL = ENV_TOKENS["CONTACT_EMAIL"]

View File

@ -8,12 +8,10 @@ execfile(os.path.join(os.path.dirname(__file__), "common.py"), globals())
ALLOWED_HOSTS = [ ALLOWED_HOSTS = [
ENV_TOKENS.get("LMS_BASE"), ENV_TOKENS.get("LMS_BASE"),
FEATURES["PREVIEW_LMS_BASE"], FEATURES["PREVIEW_LMS_BASE"],
"lms",
"127.0.0.1", "127.0.0.1",
"localhost", "localhost",
"preview.localhost", "preview.localhost",
"127.0.0.1:8000",
"localhost:8000",
"preview.localhost:8000",
] ]
# Required to display all courses on start page # Required to display all courses on start page