Created
December 1, 2011 11:42
-
-
Save sneeu/1416104 to your computer and use it in GitHub Desktop.
This file contains hidden or 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 default; | |
access_log /var/www/sagan/logs/nginx.access.log; | |
error_log /var/www/sagan/logs/nginx.error.log; | |
location / { | |
root /var/www/sagan/static/; | |
try_files $uri $uri/index.html @proxy; | |
} | |
location @proxy { | |
proxy_set_header Host $host; | |
proxy_set_header X-Real-IP $remote_addr; | |
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | |
proxy_pass http://127.0.0.1:8000; | |
} | |
location /media { | |
alias /var/www/sagan/media; | |
} | |
location /google2e84deffb90c47c8.html { | |
alias /var/www/sagan/static/google2e84deffb90c47c8.html; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Found the solution to creating a static home-page at / in the Nginx forum.