Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Launch Celery without a virtualenv

I'm trying to launch Celery installed with pip in a Docker container that doesn't use virtualenv.

celery: command not found

I tried to run

python /usr/local/lib/python3.4/site-packages/celery/bin/celery.py

but get ImportError: No module named 'celery.five'; 'celery' is not a package

When I do pip freeze I can see it's installed.

Running the command from a virtualenv works because celery is added to <VENV>/bin/celery and <VENV>/bin/ is prepended to my $PATH.

How can I run Celery without using a virtualenv?

like image 336
Felix D. Avatar asked Jan 23 '26 16:01

Felix D.


1 Answers

Inside an installation using system's Python, the command pip install celery will usually install the binary under /usr/local/bin, so make sure that's in the $PATH.

like image 113
Elias Dorneles Avatar answered Jan 25 '26 07:01

Elias Dorneles



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!