From bf83fba664afa8257c79c1d23717b22e5274650c Mon Sep 17 00:00:00 2001 From: Andreas Gerstenberg Date: Mon, 13 Nov 2017 11:25:18 +0100 Subject: [PATCH] spk-spar-checker update header --- customer/spk-spar-checker/production.yaml | 42 +++++++++++++++++++---- 1 file changed, 36 insertions(+), 6 deletions(-) diff --git a/customer/spk-spar-checker/production.yaml b/customer/spk-spar-checker/production.yaml index fa20661d..054573f2 100644 --- a/customer/spk-spar-checker/production.yaml +++ b/customer/spk-spar-checker/production.yaml @@ -78,13 +78,43 @@ infra::profile::apache::pp_vhosts: directoryindex: 'index.html' custom_fragment: | AddType text/plain .tmpl + + ## Configuration of the cache expiration + # Images and Fonts are versioned and should be cached 1 year + # JS and CSS are versioned, but should only be cached for 1 month + # The rest should not be cached ExpiresActive On - ExpiresDefault A0 - - ExpiresDefault A0 - Header set Cache-Control "no-cache, no-store, must-revalidate, max-age=0, proxy-revalidate, no-transform" - Header set Pragma "no-cache" - + ExpiresDefault A2592000 + + # Versioned assets + ExpiresByType image/png A31536000 + ExpiresByType image/gif A31536000 + ExpiresByType image/jpeg A31536000 + ExpiresByType image/svg+xml A31536000 + ExpiresByType application/x-font-ttf A31536000 + ExpiresByType application/x-font-truetype A31536000 + ExpiresByType application/x-font-opentype A31536000 + ExpiresByType application/font-sfnt A31536000 + ExpiresByType application/vnd.ms-fontobject A31536000 + ExpiresByType application/font-woff A31536000 + ExpiresByType application/font-woff2 A31536000 + + # Versioned code + ExpiresByType text/css A2592000 + ExpiresByType application/javascript A2592000 + + # Not versioned assets + ExpiresByType application/manifest+json A0 + ExpiresByType text/plain A0 + ExpiresByType text/html A0 + ExpiresByType application/x-web-app-manifest+json A0 + ExpiresByType text/cache-manifest A0 + ExpiresByType application/json A0 + ExpiresByType application/ld+json A0 + ExpiresByType application/schema+json A0 + ExpiresByType application/vnd.geo+json A0 + ExpiresByType text/javascript A0 + ExpiresByType text/xml A0 rewrites: - comment: 'frontend root rewrite' -- 2.39.5