diff --git a/cms/envs/production.py b/cms/envs/production.py index 6e39cf02c0..c6a0f090f3 100644 --- a/cms/envs/production.py +++ b/cms/envs/production.py @@ -89,7 +89,6 @@ with codecs.open(CONFIG_FILE, encoding='utf-8') as f: 'EVENT_BUS_PRODUCER_CONFIG', 'DEFAULT_FILE_STORAGE', 'STATICFILES_STORAGE', - 'ALLOWED_HOSTS', ] }) @@ -140,10 +139,6 @@ if STATIC_ROOT_BASE: DATA_DIR = path(DATA_DIR) -# If ALLOWED_HOSTS is explicitly set in YAML, use it as the base; otherwise use default from common.py -if 'ALLOWED_HOSTS' in _YAML_TOKENS: - _BASE_ALLOWED_HOSTS = _YAML_TOKENS['ALLOWED_HOSTS'] - # Cache used for location mapping -- called many times with the same key/value # in a given request. if 'loc_cache' not in CACHES: diff --git a/lms/envs/production.py b/lms/envs/production.py index 7e48a3c682..aeccaf0c0f 100644 --- a/lms/envs/production.py +++ b/lms/envs/production.py @@ -84,7 +84,6 @@ with codecs.open(CONFIG_FILE, encoding='utf-8') as f: 'EVENT_BUS_PRODUCER_CONFIG', 'DEFAULT_FILE_STORAGE', 'STATICFILES_STORAGE', - 'ALLOWED_HOSTS', ] }) @@ -142,10 +141,6 @@ SESSION_COOKIE_SAMESITE = DCS_SESSION_COOKIE_SAMESITE for feature, value in _YAML_TOKENS.get('FEATURES', {}).items(): FEATURES[feature] = value -# If ALLOWED_HOSTS is explicitly set in YAML, use it as the base; otherwise use default from common.py -if 'ALLOWED_HOSTS' in _YAML_TOKENS: - _BASE_ALLOWED_HOSTS = _YAML_TOKENS['ALLOWED_HOSTS'] - # Cache used for location mapping -- called many times with the same key/value # in a given request. if 'loc_cache' not in CACHES: diff --git a/openedx/envs/common.py b/openedx/envs/common.py index 18fa201382..e9033a1759 100644 --- a/openedx/envs/common.py +++ b/openedx/envs/common.py @@ -2258,6 +2258,10 @@ AI_TRANSLATIONS_API_URL = 'http://localhost:18760/api/v1' def should_send_learning_badge_events(settings): return settings.BADGES_ENABLED +############################## ALLOWED_HOSTS ############################### + +ALLOWED_HOSTS = ['*'] + ############################## Miscellaneous ############################### COURSE_MODE_DEFAULTS = {