I'm learning Celery and I'd like to ask:
- Which is the absolute simplest way to get Celery to automatically run when Django starts in Ubuntu?. Now I manually start
celery -A {prj name} worker -l INFO
via the terminal. - Can I make any type of configuration so Celery catches the changes in
tasks.py
code without the need to restart Celery? Now Ictrl+c
and typecelery -A {prj name} worker -l INFO
every time I change something in thetasks.py
code. I can foresee a problem in such approach in production if I can get Celery start automatically ==> need to restart Ubuntu instead?.
(setup: VPS, Django, Ubuntu 18.10 (no docker), no external resources, using Redis (that starts automatically)
I am aware it is a similar question to Django-Celery in production and How to ... but still it is a bit unclear as it refers to amazon and also using shell scripts, crontabs. It seems a bit peculiar that these things wouldn't work out of the box.
I give benefit to the doubt that I have misunderstood the setup of Celery.