X-Git-Url: https://git.openstreetmap.org./chef.git/blobdiff_plain/00067ab27e488394fcef9f47d26a93c2fbb0523e..cac6ace6749429cdc77d0f1c0bac4890838d0861:/cookbooks/tile/templates/default/apache.erb diff --git a/cookbooks/tile/templates/default/apache.erb b/cookbooks/tile/templates/default/apache.erb index 8df11453b..182b590e5 100644 --- a/cookbooks/tile/templates/default/apache.erb +++ b/cookbooks/tile/templates/default/apache.erb @@ -12,8 +12,8 @@ # SSLEngine on SSLProxyEngine on - SSLCertificateFile /etc/ssl/certs/<%= node.name %>.pem - SSLCertificateKeyFile /etc/ssl/private/<%= node.name %>.key + SSLCertificateFile /etc/ssl/certs/<%= node[:fqdn] %>.pem + SSLCertificateKeyFile /etc/ssl/private/<%= node[:fqdn] %>.key # Configure location of static files and CGI scripts DocumentRoot /srv/tile.openstreetmap.org/html @@ -40,6 +40,9 @@ # Add diagnostics header to identify render server Header set X-TileRender "<%= node.name %>" + # Tell clients to use stale tiles if necessary + Header append Cache-Control "stale-while-revalidate=604800, stale-if-error=604800" "expr=%{CONTENT_TYPE} == 'image/png'" + # Remove Proxy request header to mitigate https://httpoxy.org/ RequestHeader unset Proxy early