mirror of
https://github.com/welton89/RRBEC.git
synced 2026-04-05 21:45:41 +00:00
feat: configure CSRF_TRUSTED_ORIGINS via environment variables for production domains
This commit is contained in:
@@ -39,7 +39,11 @@ SECRET_KEY = os.getenv(
|
||||
# SECURITY WARNING: don't run with debug turned on in production!
|
||||
DEBUG = os.getenv("DEBUG", "True") == "True"
|
||||
|
||||
ALLOWED_HOSTS = ["*"]
|
||||
CSRF_TRUSTED_ORIGINS = (
|
||||
os.getenv("CSRF_TRUSTED_ORIGINS", "").split(",")
|
||||
if os.getenv("CSRF_TRUSTED_ORIGINS")
|
||||
else []
|
||||
)
|
||||
|
||||
|
||||
# Application definition
|
||||
|
||||
Reference in New Issue
Block a user