Closed longhotsummer closed 9 years ago
Not being up to date with Django, this is the first time I hear about staticfiles.json
.
I have two ideas:
staticfiles.json
. My vote is for django-assets being aware enough to add entries to staticfiles.json. Does the webassets builder return the output filenames for what it has compiled?
I'm sure there is some way to get at the info. The right place would probably be an overwritten version of the "build" command.
I run
collectstatic
and thenbuild assets
to compile and version my assets in production (webassets does the versioning). I use Whitenoise to serve production assets and (in theory) ensure far-future expire headers for fingerprinted assets.However, Whitenoise doesn't think the compiled, versioned assets should have an far-futures expired header set because they aren't in the staticfiles.json manifest.
If I run
collectstatic
again afterbuild assets
it fingerprints the already fingerprinted files.Is there a way we can solve this or work around it?
Key parts of my settings.py:
In assets.py: