Caddyfile (view raw)
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 | { admin off persist_config off http_port 8080 } :9091 { metrics } http://www.alanpearce.eu { header Cache-Control max-age=31536000 redir https://alanpearce.eu{uri} } http://alanpearce.eu { root * {$SITE_ROOT} file_server { precompressed br zstd gzip } header { Cache-Control max-age=14400 X-Content-Type-Options nosniff Strict-Transport-Security "max-age=31536000; includeSubDomains; preload" } handle_errors { @404 expression `{err.status_code} == 404` handle @404 { rewrite * /404.html } file_server { precompressed br zstd gzip } } header /feed-styles/ Content-Type text/xsl error /feed-styles/index.html* 404 respond /favicon.ico 204 redir /index.xml /atom.xml redir /post/index.xml /atom.xml } |