Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Celery is not started automatically from docker #60

Open
rgraf opened this issue Aug 3, 2020 · 1 comment
Open

Celery is not started automatically from docker #60

rgraf opened this issue Aug 3, 2020 · 1 comment

Comments

@rgraf
Copy link
Collaborator

rgraf commented Aug 3, 2020

This can be checked in dashboard: http://localhost:8000/earkweb/administration/dashboard Sometimes Celery does not start automatically from docker deployment. This can be fixed, when you start it manually from inside earkweb1 running docker container:

in one terminal:
root@2eb1e1400ec7:/earkweb# cat run_all.sh
#!/bin/bash
sleep 20
echo "Starting celery ..."

cd /earkweb && celery multi start ingestqueue -A earkweb.celery --concurrency=4 -Ofair --pidfile=/data/celery_worker.pid --logfile=/data/celery_default_queue.log

cd /earkweb && celery -A earkweb.celery worker --pool threads -Ofair --pidfile=/data/celery_worker.pid --logfile=/data/celery_default_queue.log &

cd /earkweb && celery -A earkweb.celery worker --pool prefork -Ofair --pidfile=/var/data/celery_worker.pid --logfile=/var/data/celery_default_queue.log &
sleep 3
echo "Starting flower ..."
cd /earkweb && celery -A earkweb.celery flower --port=5555 >/var/data/flower.log 2>&1 &
sleep 3
echo "Starting earkweb ..."
cd /earkweb && python3 manage.py runserver 0.0.0.0:8000
root@2eb1e1400ec7:/earkweb# celery -A earkweb.celery worker --pool prefork -Ofair

in the second terminal:
root@osboxes:/home/osboxes# docker exec -it earkweb1 /bin/bash
root@2eb1e1400ec7:/# cd earkweb
root@2eb1e1400ec7:/earkweb# celery -A earkweb.celery status

@bartham
Copy link
Collaborator

bartham commented Sep 30, 2020

Celery starts successfully. Problem was running docker in sandbox via snap. Deployed on test server.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants