|
|
@ -9,7 +9,8 @@ https://docs.djangoproject.com/en/1.6/ref/settings/ |
|
|
|
""" |
|
|
|
""" |
|
|
|
|
|
|
|
|
|
|
|
# Build paths inside the project like this: os.path.join(BASE_DIR, ...) |
|
|
|
# Build paths inside the project like this: os.path.join(BASE_DIR, ...) |
|
|
|
import os, sys |
|
|
|
import os |
|
|
|
|
|
|
|
import sys |
|
|
|
BASE_DIR = os.path.dirname(os.path.dirname(__file__)) |
|
|
|
BASE_DIR = os.path.dirname(os.path.dirname(__file__)) |
|
|
|
|
|
|
|
|
|
|
|
CLOSED = False |
|
|
|
CLOSED = False |
|
|
@ -26,7 +27,7 @@ DEBUG = False |
|
|
|
if 'runserver' in sys.argv: |
|
|
|
if 'runserver' in sys.argv: |
|
|
|
DEBUG = True |
|
|
|
DEBUG = True |
|
|
|
|
|
|
|
|
|
|
|
ALLOWED_HOSTS = ['websec.paulwagener.nl'] |
|
|
|
ALLOWED_HOSTS = ['websec.paulwagener.nl', '127.0.0.1'] |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# Application definition |
|
|
|
# Application definition |
|
|
@ -43,7 +44,7 @@ INSTALLED_APPS = ( |
|
|
|
'corsheaders', |
|
|
|
'corsheaders', |
|
|
|
) |
|
|
|
) |
|
|
|
|
|
|
|
|
|
|
|
MIDDLEWARE_CLASSES = ( |
|
|
|
MIDDLEWARE = ( |
|
|
|
'django.contrib.sessions.middleware.SessionMiddleware', |
|
|
|
'django.contrib.sessions.middleware.SessionMiddleware', |
|
|
|
'django.middleware.common.CommonMiddleware', |
|
|
|
'django.middleware.common.CommonMiddleware', |
|
|
|
'django.middleware.csrf.CsrfViewMiddleware', |
|
|
|
'django.middleware.csrf.CsrfViewMiddleware', |
|
|
@ -101,7 +102,6 @@ TEMPLATES = [ |
|
|
|
'django.template.context_processors.debug', |
|
|
|
'django.template.context_processors.debug', |
|
|
|
'django.template.context_processors.request', |
|
|
|
'django.template.context_processors.request', |
|
|
|
'django.contrib.auth.context_processors.auth', |
|
|
|
'django.contrib.auth.context_processors.auth', |
|
|
|
'securityquiz.settings.closed', |
|
|
|
|
|
|
|
'django.contrib.messages.context_processors.messages', |
|
|
|
'django.contrib.messages.context_processors.messages', |
|
|
|
], |
|
|
|
], |
|
|
|
}, |
|
|
|
}, |
|
|
@ -111,6 +111,3 @@ TEMPLATES = [ |
|
|
|
STATICFILES_DIRS = ( |
|
|
|
STATICFILES_DIRS = ( |
|
|
|
PROJECT_PATH + '/static', |
|
|
|
PROJECT_PATH + '/static', |
|
|
|
) |
|
|
|
) |
|
|
|
|
|
|
|
|
|
|
|
def closed(request): |
|
|
|
|
|
|
|
return {'CLOSED': CLOSED} |
|
|
|
|
|
|
|