2014-03-27 26 views
0

我知道這已經提出,但我仍然無法使它的工作。我更改了urls.py文件中的urls路徑。這些更改未被應用。該文件的舊版本仍在運行。stubborn urls.py - 無法重新加載它下nginx

我試過重新加載nginx服務器,但它沒有幫助。我用gunicorn在nginx下運行我的django項目。

回答

1

不知道你的設置(nginx + gunicorn + django?),我認爲你需要重新啓動gunicorn才能重新載入python/django應用程序。

+0

這幫了我,謝謝!爲了更具體的下一代:從$ ps aux獲得pid。然後重新加載gunicorn:$ kill -HUP

+0

太棒了!我建議您不要手動啓動gunicorn,而是使用進程監視器(http://docs.gunicorn.org/en/latest/deploy.html#monitoring),例如supervisor(http://supervisord.org/)。 – HAL

+0

它已經在它下面運行了。我應該選擇哪個選項來重新啓動它,$ supervisorctl restart? –