diff --git a/credentials/settings/production.py b/credentials/settings/production.py index 9d9853098..ea7e7b1b0 100644 --- a/credentials/settings/production.py +++ b/credentials/settings/production.py @@ -29,6 +29,10 @@ AWS_SES_REGION_NAME = environ.get("AWS_SES_REGION_NAME", "us-east-1") AWS_SES_REGION_ENDPOINT = environ.get("AWS_SES_REGION_ENDPOINT", "email.us-east-1.amazonaws.com") +# Inject plugin settings before the configuration file overrides (so it is possible to manage those settings via environment). +add_plugins(__name__, PROJECT_TYPE, SettingsType.PRODUCTION) + + CONFIG_FILE = get_env_setting("CREDENTIALS_CFG") with open(CONFIG_FILE, encoding="utf-8") as f: config_from_yaml = yaml.safe_load(f) @@ -60,5 +64,3 @@ for override, value in DB_OVERRIDES.items(): DATABASES["default"][override] = value - -add_plugins(__name__, PROJECT_TYPE, SettingsType.PRODUCTION)