allowed hosts

This commit is contained in:
root (lxc-fetsite-04)
2020-10-10 12:02:45 +02:00
parent b38a0d69fa
commit 971d68c06a
4 changed files with 16 additions and 4 deletions

View File

@@ -19,7 +19,8 @@ env = environ.Env(
MYSQL_PORT=(int, 3308),
MYSQL_DATABASE=(str, "fet2020db"),
MYSQL_USER=(str),
MYSQL_PASSWORD=(str)
MYSQL_PASSWORD=(str),
HOST_NAME=(str, "localhost")
)
# Prints and logs are written to console
@@ -56,7 +57,7 @@ else:
SECRET_KEY = env('SECRET_KEY')
ALLOWED_HOSTS = ["127.0.0.1", "localhost"]
ALLOWED_HOSTS = ["127.0.0.1", env('HOST_NAME')]
DATA_UPLOAD_MAX_MEMORY_SIZE = 1024 * 1024 * 1024

View File

@@ -1,3 +1,3 @@
#!/bin/sh
python manage.py makemigrations && python manage.py makemigrations posts members \
&& python manage.py migrate
python manage.py makemigrations && python manage.py makemigrations posts members blackboard\
&& python manage.py migrate