diff --git a/files/sao-cache.conf b/files/sao-cache.conf new file mode 100644 index 0000000..971af04 --- /dev/null +++ b/files/sao-cache.conf @@ -0,0 +1,33 @@ +# Verwaltet durch Ansible (Rolle "apache2") + + + ExpiresActive on + + # Favicon (cannot be renamed) + ExpiresByType image/x-icon "access plus 1 week" + + # Media: images, video, audio + ExpiresByType image/gif "access plus 1 month" + ExpiresByType image/png "access plus 1 month" + ExpiresByType image/jpg "access plus 1 month" + ExpiresByType image/jpeg "access plus 1 month" + ExpiresByType video/ogg "access plus 1 month" + ExpiresByType audio/ogg "access plus 1 month" + ExpiresByType video/mp4 "access plus 1 month" + ExpiresByType video/webm "access plus 1 month" + + # Webfonts + ExpiresByType application/x-font-ttf "access plus 1 month" + ExpiresByType font/opentype "access plus 1 month" + ExpiresByType application/x-font-woff "access plus 1 month" + ExpiresByType image/svg+xml "access plus 1 month" + + # CSS and JavaScript + ExpiresByType text/css "access plus 1 month" + ExpiresByType text/javascript "access plus 1 month" + ExpiresByType application/javascript "access plus 1 month" + + + Header append Cache-Control "public" + + diff --git a/tasks/configuration.yml b/tasks/configuration.yml index 5dc4873..6678e4d 100644 --- a/tasks/configuration.yml +++ b/tasks/configuration.yml @@ -16,4 +16,5 @@ loop: - add-headers.conf - letsencrypt.conf + - sao-cache.conf - ssl.conf