fix: avoid cached static hash urls
All checks were successful
Build and Push Docker Image / build (push) Successful in 26s
All checks were successful
Build and Push Docker Image / build (push) Successful in 26s
This commit is contained in:
@@ -1,6 +1,7 @@
|
|||||||
SECRET_KEY=replace-me
|
SECRET_KEY=replace-me
|
||||||
DEBUG=false
|
DEBUG=false
|
||||||
LOG_LEVEL=info
|
LOG_LEVEL=info
|
||||||
|
WHITENOISE_USE_MANIFEST=false
|
||||||
WHITENOISE_MANIFEST_STRICT=false
|
WHITENOISE_MANIFEST_STRICT=false
|
||||||
ALLOWED_HOSTS=example.com,www.example.com
|
ALLOWED_HOSTS=example.com,www.example.com
|
||||||
CSRF_TRUSTED_ORIGINS=https://example.com,https://www.example.com
|
CSRF_TRUSTED_ORIGINS=https://example.com,https://www.example.com
|
||||||
|
|||||||
@@ -265,6 +265,7 @@ STATICFILES_DIRS = [
|
|||||||
STATIC_ROOT = BASE_DIR / 'staticfiles'
|
STATIC_ROOT = BASE_DIR / 'staticfiles'
|
||||||
|
|
||||||
# Whitenoise storage for compressed static files
|
# Whitenoise storage for compressed static files
|
||||||
|
WHITENOISE_USE_MANIFEST = env_bool("WHITENOISE_USE_MANIFEST", False)
|
||||||
STORAGES = {
|
STORAGES = {
|
||||||
'default': {
|
'default': {
|
||||||
'BACKEND': 'django.core.files.storage.FileSystemStorage',
|
'BACKEND': 'django.core.files.storage.FileSystemStorage',
|
||||||
@@ -273,12 +274,17 @@ STORAGES = {
|
|||||||
'BACKEND': (
|
'BACKEND': (
|
||||||
'django.contrib.staticfiles.storage.StaticFilesStorage'
|
'django.contrib.staticfiles.storage.StaticFilesStorage'
|
||||||
if DEBUG else
|
if DEBUG else
|
||||||
'whitenoise.storage.CompressedManifestStaticFilesStorage'
|
(
|
||||||
|
'whitenoise.storage.CompressedManifestStaticFilesStorage'
|
||||||
|
if WHITENOISE_USE_MANIFEST else
|
||||||
|
'whitenoise.storage.CompressedStaticFilesStorage'
|
||||||
|
)
|
||||||
),
|
),
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
# Keep the app serving even if a deployment has a stale or incomplete manifest.
|
# Keep the app serving even if a deployment has a stale or incomplete manifest.
|
||||||
|
# This only matters when WHITENOISE_USE_MANIFEST=true.
|
||||||
WHITENOISE_MANIFEST_STRICT = env_bool("WHITENOISE_MANIFEST_STRICT", False)
|
WHITENOISE_MANIFEST_STRICT = env_bool("WHITENOISE_MANIFEST_STRICT", False)
|
||||||
|
|
||||||
# Default primary key field type
|
# Default primary key field type
|
||||||
|
|||||||
Reference in New Issue
Block a user