From 6ee66e6f013f2dec8e6d665e65758aacc26dc5d5 Mon Sep 17 00:00:00 2001 From: phil Date: Tue, 26 Jul 2022 17:45:32 +0200 Subject: [PATCH] apache2: Kopiere Cache-Konfiguration --- files/sao-cache.conf | 33 +++++++++++++++++++++++++++++++++ tasks/configuration.yml | 1 + 2 files changed, 34 insertions(+) create mode 100644 files/sao-cache.conf 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