Add option to set CSRF_TRUSTED_ORIGINS (Django 4.0)
This commit is contained in:
parent
e08c6e790b
commit
e7fef3b2f8
@ -26,8 +26,9 @@ SERVER_EMAIL=Shynet <noreply@shynet.example.com>
|
||||
# General Django settings
|
||||
DJANGO_SECRET_KEY=random_string
|
||||
|
||||
# For better security, set this to your deployment's domain. Comma separated.
|
||||
# For better security, set these to your deployment's domain. Comma separated.
|
||||
ALLOWED_HOSTS=*
|
||||
CSRF_TRUSTED_ORIGINS=*
|
||||
|
||||
# Localization
|
||||
# https://docs.djangoproject.com/en/2.2/topics/i18n/
|
||||
|
@ -39,7 +39,7 @@ SECRET_KEY = os.getenv("DJANGO_SECRET_KEY", "onlyusethisindev")
|
||||
DEBUG = os.getenv("DEBUG", "False") == "True"
|
||||
|
||||
ALLOWED_HOSTS = os.getenv("ALLOWED_HOSTS", "*").split(",")
|
||||
|
||||
CSRF_TRUSTED_ORIGINS = os.getenv("CSRF_TRUSTED_ORIGINS", "*").split(",")
|
||||
|
||||
# Application definition
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user