samhuri.net/public/.htaccess

27 lines
772 B
ApacheConf

DefaultType text/html
AddType audio/mp4 m4r
AddType application/rss+xml rss
SetOutputFilter DEFLATE
# Turn on Expires and set default expires to 3 days
ExpiresActive On
ExpiresDefault A259200
# Set up caching on media files for 1 month
<FilesMatch "\.(ico|gif|jpg|jpeg|png|pdf|mov|mp3|m4r|m4a)$">
ExpiresDefault A2419200
Header append Cache-Control "public"
SetOutputFilter NONE
</FilesMatch>
# Set up 2 week caching on commonly updated files
<FilesMatch "\.(xml|txt|html|js|css|rss)$">
ExpiresDefault A1209600
Header append Cache-Control "private, must-revalidate"
</FilesMatch>
Redirect 301 /proj/ /projects/
Redirect 301 /blog/sjs.rss /feed.xml
Redirect 301 /blog/ /posts/
Redirect 301 /json-diff/ http://tlrobinson.net/projects/javascript-fun/jsondiff/