2017-10-06 11 views
0

私は、起動スクリプトを使用して、ドッキングウィンドウコンテナに私のDjangoのアプリを起動し、以下のあたりのように: -ユニコーンとnginxのとジャンゴ、作成gunicornログ

#!/bin/bash 
python manage.py collectstatic --noinput 
python manage.py makemigrations 
python manage.py migrate 
/etc/init.d/celeryd start 
/etc/init.d/celerybeat start 
exec gunicorn itapp.wsgi -b 0.0.0.0:8000 

ユニコーン、今、すべてのをngnixして、私に502を与えますエラーが発生しましたので、ログを検索しましたが、デフォルトではgunicornはログに記録されません。バージョン19.7.1

上のイムので、私は、exec guncicornコマンドに追加:私はgunicornのドキュメントを形成ゴイ

exec gunicorn itapp.wsgi -b 0.0.0.0:8000 --error-logfile /var/log/gunicorn/errors.log , --log-file /var/log/gunicorn/access.log 

。しかし今Gunicornは、次のエラーで起動に失敗します -

usage: gunicorn [OPTIONS] [APP_MODULE] 
gunicorn: error: unrecognized arguments: , 

は、どのように私はこれらのエラーをデバッグするgunicornログを作成することができますか?

おかげ

答えて

1

カンマを削除し、あなたは問題ないはずです。

exec gunicorn itapp.wsgi -b 0.0.0.0:8000 --error-logfile /var/log/gunicorn/errors.log --log-file /var/log/gunicorn/access.log 
+0

theresのエラーなしに、それは1c9eda388c90 @ errors.logルートを作成しているようには見えません:/ itapp/itapp#のLSは/ var/log/gunicorn/ access.log 初めてエラーが発生した場合にのみエラーを作成しますか?ありがとう – AlexW

+0

@AlexWはい、そこに新しいエラーだけが現れます –

関連する問題