mirror of
https://github.com/meineerde/holgerjust.de.git
synced 2026-02-22 11:32:03 +00:00
26 lines
781 B
Plaintext
26 lines
781 B
Plaintext
---
|
|
noindex: true
|
|
layout: false
|
|
---
|
|
# Compress files on the fly
|
|
AddOutputFilterByType DEFLATE text/html text/plain text/xml text/css application/javascript text/javascript
|
|
|
|
# Aggressively cache assets
|
|
ExpiresActive On
|
|
ExpiresDefault "access plus 1 year"
|
|
|
|
# Cache only very shortly on non cache-busted files
|
|
ExpiresByType text/html "access plus 1 hour"
|
|
ExpiresByType text/xml "access"
|
|
|
|
RewriteEngine On
|
|
|
|
# Require SSL
|
|
RewriteCond %{HTTPS} !=on
|
|
RewriteCond %{ENV:HTTPS} !=on
|
|
RewriteRule .* https://<%= URI.parse(casper[:blog][:url]).host %>%{REQUEST_URI} [R=301,L,QSA]
|
|
|
|
# Ensure we only use the canonical hostname
|
|
RewriteCond %{HTTP_HOST} !=<%= URI.parse(casper[:blog][:url]).host %> [NC]
|
|
RewriteRule .* https://<%= URI.parse(casper[:blog][:url]).host %>%{REQUEST_URI} [R=301,L,QSA]
|