5
votes

I'm using several django instances, each in a virtualenv, on the same server. How can I start the celery server and make sure it is always running and updated? I.e. after a server restart or code update?

The /etc/init.d script and the config file assume a single Django installation. Do I have to use the ./manage.py celeryd command?

Regards Simon

2
How do you start your djangos ?jpic
djangos are started through runner.wsgisbaechler

2 Answers

3
votes

You should look at django celery. This allows you to use the manage.py celeryd command for each project in it's own virtualenv. You can daemonize these processes with supervisord and manage them individually.

Check out http://ask.github.com/celery/cookbook/daemonizing.html#supervisord for guidance.

1
votes

If you make changes in tasks.py for celery, then you will have to restart it once to apply changes by running command ./manage.py celeryd start or python manage.py celeryd start --settings=settings for using settings.py as configuration for celery. It will not be affected by the changes in your projects until you make changes in celery configuration.