在celery文件所在目录:
- linux 前台启动:
/usr/local/python3/bin/celery worker -A workr_name -l info -P gevent -b redis://127.0.0.1:6379/0 -Q workr_name
关闭: Ctrl + C
- linux 后台启动:
/usr/local/python3/bin/celery multi start -A workr_name -l warn -c 100 -P gevent -Q workr_name -b redis://127.0.0.1:6379/0
关闭: start------>stop
-A -c -l -P -Q -b不做解释了
- windows 前台启动
celery worker -A workr_name -l info -P eventlet -b redis://redis_ip:6379/0-Q workr_name
关闭: Ctrl + C
workr_name: 启动文件名(不带后缀)
linux: -P gevent
windows: -P eventlet
网友评论