推荐学习书目
Learn Python the Hard Way
Python Sites
PyPI - Python Package Index
http://diveintopython.org/toc/index.html
Pocoo
值得关注的项目
PyPy
Celery
Jinja2
Read the Docs
gevent
pyenv
virtualenv
Stackless Python
Beautiful Soup
结巴中文分词
Green Unicorn
Sentry
Shovel
Pyflakes
pytest
Python 编程
pep8 Checker
Styles
PEP 8
Google Python Style Guide
Code Style from The Hitchhiker's Guide
HerrDu
V2EX  ›  Python

请教, nginx 部署 misago 的配置问题

  •  
  •   HerrDu ·
    herrdu · May 22, 2015 · 3196 views
    This topic created in 4036 days ago, the information mentioned may be changed or developed.
    配置如下,请大家看看root 的路径对不对 ,还是有别的问题 ,为啥登录 http://123.56.118.211/ 显示的内容是空?
    server {
    listen 80; ## listen for ipv4; this line is default and implied
    #listen [::]:80 default ipv6only=on; ## listen for ipv6

    root /var/www/Misago/xiabanzhihou/static;
    index index.html index.htm;

    # Make site accessible from http://localhost/
    server_name 5dk.cc;

    location / {
    # First attempt to serve request as file, then
    # as directory, then fall back to index.html
    #try_files $uri $uri/ /index.html;
    # Uncomment to enable naxsi on this location
    # include /etc/nginx/naxsi.rules
    proxy_pass http://127.0.0.1:8000;
    proxy_set_header Host $host;
    proxy_set_header X-Real-IP $remote_addr;
    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    }

    location /doc/ {
    alias /usr/share/doc/;
    autoindex on;
    allow 127.0.0.1;
    deny all;
    }

    location /static/ {
    root /var/www/Misago/xiabanzhihou/static; #Django项目所在目录
    }
    }
    No Comments Yet
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   966 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 28ms · UTC 19:30 · PVG 03:30 · LAX 12:30 · JFK 15:30
    ♥ Do have faith in what you're doing.