diff options
author | Andrew Godwin | 2022-12-15 00:35:04 -0700 |
---|---|---|
committer | Andrew Godwin | 2022-12-15 00:43:39 -0700 |
commit | 69f1b3168ac3f29fc4bafba0418769248b10062a (patch) | |
tree | 23b84b73be1f791d20c844ab4435152f8b182804 /takahe | |
parent | e0053b69ded06ef246db6239baeea87617a2621c (diff) | |
download | takahe-69f1b3168ac3f29fc4bafba0418769248b10062a.tar.gz takahe-69f1b3168ac3f29fc4bafba0418769248b10062a.tar.bz2 takahe-69f1b3168ac3f29fc4bafba0418769248b10062a.zip |
Improve cacheability
Diffstat (limited to 'takahe')
-rw-r--r-- | takahe/settings.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/takahe/settings.py b/takahe/settings.py index 4e09a10..91bfe7b 100644 --- a/takahe/settings.py +++ b/takahe/settings.py @@ -190,7 +190,7 @@ MIDDLEWARE = [ "django.contrib.messages.middleware.MessageMiddleware", "django.middleware.clickjacking.XFrameOptionsMiddleware", "django_htmx.middleware.HtmxMiddleware", - "core.middleware.AcceptMiddleware", + "core.middleware.HeadersMiddleware", "core.middleware.ConfigLoadingMiddleware", "api.middleware.ApiTokenMiddleware", "users.middleware.IdentityMiddleware", @@ -274,6 +274,10 @@ STATICFILES_FINDERS = [ STATICFILES_DIRS = [BASE_DIR / "static"] +STATICFILES_STORAGE = "django.contrib.staticfiles.storage.ManifestStaticFilesStorage" + +WHITENOISE_MAX_AGE = 3600 + STATIC_ROOT = BASE_DIR / "static-collected" ALLOWED_HOSTS = SETUP.ALLOWED_HOSTS |