fix(deploy): add use-x-forwarded-host

This commit is contained in:
2026-06-12 02:52:12 +02:00
parent 61f1457453
commit cb46fce3ce
2 changed files with 4 additions and 0 deletions
+1
View File
@@ -17,6 +17,7 @@ class Settings(BaseSettings):
allowed_hosts: list[str] = []
installed_apps: list[str] = []
api_secret: str = "selecta-secret"
force_script_name: str = ""
db_engine: str = "django.db.backends.postgresql"
db_name: str = "selecta-highscore"
+3
View File
@@ -35,6 +35,9 @@ INSTALLED_APPS = [
]
API_SECRET = env.api_secret
USE_X_FORWARDED_HOST = True
FORCE_SCRIPT_NAME = env.force_script_name
SECURE_PROXY_SSL_HEADER = ("HTTP_X_FORWARDED_PROTO", "https")
MIDDLEWARE = [
"django.middleware.security.SecurityMiddleware",