diff --git a/{{cookiecutter.project_slug}}/config/settings/base.py b/{{cookiecutter.project_slug}}/config/settings/base.py index c9feedea1..f02d476c1 100644 --- a/{{cookiecutter.project_slug}}/config/settings/base.py +++ b/{{cookiecutter.project_slug}}/config/settings/base.py @@ -252,7 +252,7 @@ ADMINS = [("""{{cookiecutter.author_name}}""", "{{cookiecutter.email}}")] MANAGERS = ADMINS # https://cookiecutter-django.readthedocs.io/en/latest/settings.html#other-environment-settings # Force the `admin` sign in process to go through the `django-allauth` workflow -DJANGO_ADMIN_FORCE_ALLAUTH = env.bool('DJANGO_ADMIN_FORCE_ALLAUTH', default=False) +DJANGO_ADMIN_FORCE_ALLAUTH = env.bool("DJANGO_ADMIN_FORCE_ALLAUTH", default=False) # LOGGING # ------------------------------------------------------------------------------ diff --git a/{{cookiecutter.project_slug}}/config/settings/production.py b/{{cookiecutter.project_slug}}/config/settings/production.py index 8ba9b5949..3a9cb10c5 100644 --- a/{{cookiecutter.project_slug}}/config/settings/production.py +++ b/{{cookiecutter.project_slug}}/config/settings/production.py @@ -110,24 +110,24 @@ AZURE_CONTAINER = env("DJANGO_AZURE_CONTAINER_NAME") {% endif -%} {% if cookiecutter.use_whitenoise == 'y' -%} STORAGES["staticfiles"] = { - "BACKEND": "whitenoise.storage.CompressedManifestStaticFilesStorage", - } + "BACKEND": "whitenoise.storage.CompressedManifestStaticFilesStorage", +} {% elif cookiecutter.cloud_provider == 'AWS' -%} STORAGES["staticfiles"] = { - "BACKEND": "{{cookiecutter.project_slug}}.utils.storages.StaticRootS3Boto3Storage", - } + "BACKEND": "{{cookiecutter.project_slug}}.utils.storages.StaticRootS3Boto3Storage", +} COLLECTFAST_STRATEGY = "collectfast.strategies.boto3.Boto3Strategy" STATIC_URL = f"https://{aws_s3_domain}/static/" {% elif cookiecutter.cloud_provider == 'GCP' -%} STORAGES["staticfiles"] = { - "BACKEND": "{{cookiecutter.project_slug}}.utils.storages.StaticRootGoogleCloudStorage", - } + "BACKEND": "{{cookiecutter.project_slug}}.utils.storages.StaticRootGoogleCloudStorage", +} COLLECTFAST_STRATEGY = "collectfast.strategies.gcloud.GoogleCloudStrategy" STATIC_URL = f"https://storage.googleapis.com/{GS_BUCKET_NAME}/static/" {% elif cookiecutter.cloud_provider == 'Azure' -%} STORAGES["staticfiles"] = { - "BACKEND": "{{cookiecutter.project_slug}}.utils.storages.StaticRootAzureStorage", - } + "BACKEND": "{{cookiecutter.project_slug}}.utils.storages.StaticRootAzureStorage", +} STATIC_URL = f"https://{AZURE_ACCOUNT_NAME}.blob.core.windows.net/static/" {% endif -%} @@ -135,18 +135,18 @@ STATIC_URL = f"https://{AZURE_ACCOUNT_NAME}.blob.core.windows.net/static/" # ------------------------------------------------------------------------------ {%- if cookiecutter.cloud_provider == 'AWS' %} STORAGES["default"] = { - "BACKEND": "{{cookiecutter.project_slug}}.utils.storages.MediaRootS3Boto3Storage", - } + "BACKEND": "{{cookiecutter.project_slug}}.utils.storages.MediaRootS3Boto3Storage", +} MEDIA_URL = f"https://{aws_s3_domain}/media/" {%- elif cookiecutter.cloud_provider == 'GCP' %} STORAGES["default"] = { - "BACKEND": "{{cookiecutter.project_slug}}.utils.storages.MediaRootGoogleCloudStorage", - } + "BACKEND": "{{cookiecutter.project_slug}}.utils.storages.MediaRootGoogleCloudStorage", +} MEDIA_URL = f"https://storage.googleapis.com/{GS_BUCKET_NAME}/media/" {%- elif cookiecutter.cloud_provider == 'Azure' %} STORAGES["default"] = { - "BACKEND": "{{cookiecutter.project_slug}}.utils.storages.MediaRootAzureStorage", - } + "BACKEND": "{{cookiecutter.project_slug}}.utils.storages.MediaRootAzureStorage", +} MEDIA_URL = f"https://{AZURE_ACCOUNT_NAME}.blob.core.windows.net/media/" {%- endif %}