fix: contact-us 405 - ALLOWED_HOSTS and CORS for production API

This commit is contained in:
Shayan Azadi
2026-02-21 12:31:40 +03:30
parent 3e100bae99
commit cc2e082d53

View File

@@ -25,7 +25,11 @@ SECRET_KEY = 'django-insecure-ro-sqgr@$*(qao)@d&ezk*z9&%+vbeurgi$b+6y650j*$1b+n5
# SECURITY WARNING: don't run with debug turned on in production!
DEBUG = True
ALLOWED_HOSTS = []
ALLOWED_HOSTS = [
'localhost',
'127.0.0.1',
'185.208.172.158',
]
# Application definition
@@ -160,6 +164,8 @@ CORS_ALLOWED_ORIGINS = [
"http://localhost:3000",
"http://127.0.0.1:5173",
"http://127.0.0.1:3000",
"http://185.208.172.158:9123",
"http://185.208.172.158",
]
CORS_ALLOW_CREDENTIALS = True