1
這是https://github.com/ask/django-celery/blob/master/contrib/supervisord/celeryd.conf提供的文件。我怎樣才能運行這個conf文件?如何使用生產中提供的celeryd.conf文件
我使用gunicorn
; =======================================
; celeryd supervisor example for Django
; =======================================
[program:celery]
command=/path/to/project/manage.py celeryd --loglevel=INFO
directory=/path/to/project
user=nobody
numprocs=1
stdout_logfile=/var/log/celeryd.log
stderr_logfile=/var/log/celeryd.log
autostart=true
autorestart=true
startsecs=10
; Need to wait for currently executing tasks to finish at shutdown.
; Increase this if you have very long running tasks.
stopwaitsecs = 600
; if rabbitmq is supervised, set its priority higher
; so it starts first
priority=998
感謝
忘記提及我正在使用gunicorn運行我的django應用程序 – user1653509
我對Gunicorn並不熟悉,但它似乎與其他任何服務器一樣。芹菜和主管與Gunicorn無關,所以我的答案仍然適用。 OTOH,如果你想[監督監督Gunicorn](http://gunicorn.org/deploy.html#supervisor),gunicorn文件告訴你如何做到這一點。我錯過了什麼嗎? – Caspar
不,我剛纔提到gunicorn,我會試試你的答案。 – user1653509