Created
June 28, 2013 21:52
-
-
Save penso/5888446 to your computer and use it in GitHub Desktop.
My server nginx configuration for my blog
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
server { | |
listen 80; | |
server_name blog.penso.info; | |
access_log /var/log/nginx/penso.access.log; | |
root /www/penso.info/htdocs; | |
index index.html index.htm; | |
location ~* \.(js|css|png|jpg|jpeg|gif|ico)$ { | |
expires 1w; | |
log_not_found off; | |
} | |
charset UTF-8; | |
gzip on; | |
gzip_vary on; | |
gzip_min_length 500; | |
gzip_proxied expired no-cache no-store private auth; | |
gzip_types text/plain text/css application/x-javascript text/xml application/xml application/xml+rss text/javascript; | |
error_page 404 /404.html; | |
# deny access to .htaccess files, if Apache's document root | |
# concurs with nginx's one | |
# | |
location ~ /\.ht { | |
deny all; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment