部署一個新應用程序的Heroku運行在myapp.herokuapp.com罰款,但會拋出一個500服務器錯誤,如果我嘗試在myapp.herokuapp.com/admin訪問管理後臺Heroku Django-Admin 500錯誤?
INSTALLED_APPS = (
...
'django.contrib.admin',
'gunicorn',
'storages',
# 'django.contrib.admindocs',
)
這裏的日誌摘錄:
2013-07-10T17:35:28.893320+00:00 heroku[web.1]: Starting process with command `python manage.py run_gunicorn -b 0.0.0.0:27294 -w 3 --log-level info`
2013-07-10T17:35:32.298226+00:00 app[web.1]: 2013-07-10 13:35:32 [2] [INFO] Starting gunicorn 0.17.4
2013-07-10T17:35:32.299005+00:00 app[web.1]: 2013-07-10 13:35:32 [2] [INFO] Using worker: sync
2013-07-10T17:35:32.298932+00:00 app[web.1]: 2013-07-10 13:35:32 [2] [INFO] Listening at: http://0.0.0.0:27294 (2)
2013-07-10T17:35:32.312781+00:00 app[web.1]: 2013-07-10 13:35:32 [11] [INFO] Booting worker with pid: 11
2013-07-10T17:35:32.388874+00:00 app[web.1]: 2013-07-10 13:35:32 [12] [INFO] Booting worker with pid: 12
2013-07-10T17:35:32.495370+00:00 heroku[web.1]: State changed from starting to up
2013-07-10T17:35:32.524196+00:00 app[web.1]: 2013-07-10 13:35:32 [13] [INFO] Booting worker with pid: 13
2013-07-10T17:35:59.929850+00:00 heroku[router]: at=info method=GET path=/ host=myapp.herokuapp.com fwd="64.119.130.116" dyno=web.1 connect=0ms service=190ms status=200 bytes=12220
2013-07-10T17:36:04.363323+00:00 heroku[router]: at=info method=GET path=/admin host=myapp.herokuapp.com fwd="64.119.130.116" dyno=web.1 connect=0ms service=4ms status=301 bytes=5
2013-07-10T17:36:04.872523+00:00 heroku[router]: at=info method=GET path=/admin/ host=myapp.herokuapp.com fwd="64.119.130.116" dyno=web.1 connect=0ms service=481ms status=500 bytes=38
哪些設置會導致應用程序正常運行,但扔在/管理一個500錯誤?我可能會忽略或錯過什麼?謝謝。
Magnus,在哨兵真棒推薦 - 以前沒有使用它。能夠診斷我自己的問題(需要爲postgres運行生產數據庫遷移) –
歡迎您! :-) – shalakhin
對於那些現在來到這裏的人來說,Sentry插件並不是免費的。起價爲29美元/月。 –