From bfcd46a5e2ac748c57763abb16f18d37b55b5d98 Mon Sep 17 00:00:00 2001 From: Dominic Date: Fri, 14 Nov 2025 20:33:39 -0500 Subject: [PATCH] wsgi stuff --- cwr/settings.py | 6 ++++-- cwr/wsgi.py | 2 +- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/cwr/settings.py b/cwr/settings.py index bd37622..766cd83 100644 --- a/cwr/settings.py +++ b/cwr/settings.py @@ -1,5 +1,6 @@ import os from pathlib import Path +from config import site_root from config import ADMIN_EMAIL_PASSWORD @@ -17,8 +18,9 @@ SECRET_KEY = 'django-insecure-l2amdti&+4frup-f-%084399hpxc19#*!j+-nyxh)!lj1^d1@g DEBUG = True DEV = True -ALLOWED_HOSTS = [] +ALLOWED_HOSTS = ['127.0.0.1', '0.0.0.0', 'cwr.domdit.com', 'domdit.com', '192.168.1.65'] +CSRF_TRUSTED_ORIGINS = ['https://cwr.domdit.com'] # Application definition INSTALLED_APPS = [ @@ -112,10 +114,10 @@ USE_TZ = True STATIC_URL = 'static/' STATIC_ROOT = 'static/' -site_root = '/home/dominic/repos/cwr' STATICFILES_DIRS = ( os.path.join(site_root, 'assets/'), ) + LOGIN_REDIRECT_URL = 'forum_threads' LOGOUT_REDIRECT_URL = "login" # Default primary key field type diff --git a/cwr/wsgi.py b/cwr/wsgi.py index f33d104..33808e0 100644 --- a/cwr/wsgi.py +++ b/cwr/wsgi.py @@ -11,6 +11,6 @@ import os from django.core.wsgi import get_wsgi_application -os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'wsgi.settings') +os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'cwr.settings') application = get_wsgi_application()