Added base nginx configuration. Added 127.0.0.1 to ALLOWED_HOSTS for nginx reverse proxy

This commit is contained in:
Felipe Martín 2013-05-22 19:00:13 +02:00
parent 1670a42975
commit e39c3fec79
2 changed files with 19 additions and 0 deletions

View File

@ -20,6 +20,7 @@ ALLOWED_HOSTS = [
'minecraftcodex.com',
'www.minecraftcodex.com',
'localhost',
'127.0.0.1',
]
# Staticfiles

View File

@ -0,0 +1,18 @@
server {
listen 80;
server_name www.minecraftcodex.com minecraftcodex.com;
#access_log logs/domain2.access.log main;
server_tokens off;
location /static {
alias /home/app/static/;
expires 30d;
autoindex on;
}
# pass requests for dynamic content to rails/turbogears/zope, et al
location / {
proxy_pass http://127.0.0.1:8000;
}
}