[l10nstats] progress background image doesn't update in docker env
Categories
(Webtools Graveyard :: Elmo, defect)
Tracking
(Not tracked)
People
(Reporter: Pike, Assigned: Pike)
References
Details
(Keywords: regression)
Attachments
(1 file, 1 obsolete file)
Assignee | ||
Comment 1•7 years ago
|
||
Comment 2•7 years ago
|
||
Comment 3•7 years ago
|
||
Comment 4•7 years ago
|
||
Comment 5•7 years ago
|
||
Assignee | ||
Comment 6•7 years ago
|
||
Assignee | ||
Comment 7•6 years ago
|
||
Brian, this is an alternative to using statics and cron (or, as now, startup).
I created a view that renders the CSS.
One challenge is that once we start caching this, the css cache might get out of sync with the image cache, so I converted the image into a data url. The problem is that much of the CSS overlaps with the image generation.
That'll require to add data: to the CSP for img-src, mind adding that to stage and prod?
This doesn't do any actual caching yet, which is more OK as we're only using a single resource, and lazy-load it. I'd like to still add caching, though.
Comment 8•6 years ago
|
||
I like this approach!
I see that we are hard-coding the csp policy in nginx for elmo, which is not something we normally do. Are you amenable to moving that into django instead? That would make changes like this easier in the future.
Comment 9•6 years ago
|
||
Also, I noticed we already have http caching set up in nginx, so as soon as you start returning a cache-control header this will be cached.
Assignee | ||
Comment 10•6 years ago
|
||
I'm up for doing the CSP directly in elmo, but I'd like to wait on https://github.com/mozilla/django-csp/issues/109 for that.
Thanks for the pointer to cache-control, I'll add that.
Assignee | ||
Comment 11•6 years ago
|
||
Meh, so close yet so far: The session middleware sets a Vary: Cookie
header, because session_csrf touches the session. We can try, but I bet that each user will get their own copy. But at least it should be locally cached while you're surfing along.
Assignee | ||
Comment 12•6 years ago
|
||
PPS: django-csp issue is fixed and released, putting that into another PR.
Assignee | ||
Comment 13•6 years ago
|
||
Assignee | ||
Comment 14•6 years ago
|
||
This works now in prod, marking FIXED.
Updated•5 years ago
|
Description
•