- last update
almost 2 years ago Patch Failed to Apply - Status changed to Closed: duplicate
almost 2 years ago 4:40pm 14 July 2023 - 🇸🇰Slovakia poker10
This is a duplicate of #3104144: Cache control header prevents proxy from minifying CSS/JS →
I have a client site that uses Cloudflare as a WAF, proxy, and CDN. They have an option to automatically minify CSS and javascript and then serve the compressed bundles from their CDN. Therefore I disable Advagg's CSS and JS compression to reduce the dependencies and save some CPU cycles on our origin server.
However I noticed Cloudflare was not minifying anything. With help from their support we discovered that Advagg is setting the following header on the aggregate bundles:
header('Cache-Control: max-age=31449600, no-transform, public');
That no-transform directive is stopping their intermediate servers from minifying the aggregates. I can confirm that removing it manually fixes the problem.
Could it be made optional, or perhaps the entire header could be stored as a Drupal variable that can be overridden? That would allow us to also modify the max-age time and/or set other directives if desired.
Closed: duplicate
2.33
Code
Not all content is available!
It's likely this issue predates Contrib.social: some issue and comment data are missing.
This is a duplicate of #3104144: Cache control header prevents proxy from minifying CSS/JS →