|
@@ -182,12 +182,18 @@ STATIC_URL = "/static/"
|
|
|
MEDIA_ROOT = os.path.join(PROJECT_DIR, "media")
|
|
|
MEDIA_URL = "/media/"
|
|
|
|
|
|
+# Default storage settings, with the staticfiles storage updated.
|
|
|
+# See https://docs.djangoproject.com/en/stable/ref/settings/#std-setting-STORAGES
|
|
|
STORAGES = {
|
|
|
"default": {
|
|
|
"BACKEND": "django.core.files.storage.FileSystemStorage",
|
|
|
},
|
|
|
+ # ManifestStaticFilesStorage is recommended in production, to prevent
|
|
|
+ # outdated JavaScript / CSS assets being served from cache
|
|
|
+ # (e.g. after a Wagtail upgrade).
|
|
|
+ # See https://docs.djangoproject.com/en/stable/ref/contrib/staticfiles/#manifeststaticfilesstorage
|
|
|
"staticfiles": {
|
|
|
- "BACKEND": "django.contrib.staticfiles.storage.StaticFilesStorage",
|
|
|
+ "BACKEND": "django.contrib.staticfiles.storage.ManifestStaticFilesStorage",
|
|
|
},
|
|
|
}
|
|
|
|