peterbe / django-static

Template tags for better serving static files from templates in Django
BSD 2-Clause "Simplified" License
193 stars 28 forks source link

Feature Request: Allow a Custom Nonce Rather than file m_time #19

Open umbrae opened 13 years ago

umbrae commented 13 years ago

Hi there,

We're happy users of django-static, but we've run into a couple problems with our load balanced configuration that would make it a lot easier if we could guarantee that the nonce being used will be the same across all of our boxes.

With that in mind, we figured we could change the nonce to just be our current version number - that way it's replicatable across all boxes, and it still has all of the same benefits of django-static in production.

Would you consider allowing a custom parameter - maybe something like DJANGO_STATIC_CUSTOM_NONCE - that could be set in settings.py and always used instead of file mtime?

Thanks, any thoughts appreciated!

peterbe commented 13 years ago

I replied by email. Did that reach you?

umbrae commented 13 years ago

Hi Peter - I don't think I received anything - maybe try chrisd@arc90.com?

peterbe commented 13 years ago

I could certainly consider that. As long as the number is suitable in a URL. Also I've decided not to accept pull requests that don't have tests. They might not all pass but please try to include some. Peter

(that's what I wrote in the email reply)