-
-
Notifications
You must be signed in to change notification settings - Fork 152
Description
Description
The docs for WHITENOISE_KEEP_ONLY_HASHED_FILES indicate that it can be used to keep only hashed versions of files, which is useful for reducing the size of static files that need to be included in e.g: a Docker image or uploaded to a CDN. This sounds like it's potentially very useful, both for storage costs and build times.
However it's not clear how to use this together with WHITENOISE_ROOT, where you typically do want the non-hashed filenames (though only for a very small number of files).
Is there something in Whitenoise which can translate from the non-hashed names to the hashed names, so that at runtime both are served? Or are these two options incompatible?
Is there a way to use these together for most files, but then to keep the plain filenames around for those in WHITENOISE_ROOT? (Given the small number and likely small size of the latter, maintaining the duplication here feels reasonable).