diff --git a/bin/mprocs.yaml b/bin/mprocs.yaml index f57efc845d834..aeb843bab051a 100644 --- a/bin/mprocs.yaml +++ b/bin/mprocs.yaml @@ -1,9 +1,9 @@ procs: celery-worker: - shell: 'bin/check_kafka_clickhouse_up && source ./bin/celery-queues.env && python manage.py run_autoreload_celery --type=worker' + shell: 'bin/check_kafka_clickhouse_up && ./bin/start-celery worker' celery-beat: - shell: 'bin/check_kafka_clickhouse_up && source ./bin/celery-queues.env && python manage.py run_autoreload_celery --type=beat' + shell: 'bin/check_kafka_clickhouse_up && ./bin/start-celery beat' plugin-server: shell: 'bin/check_kafka_clickhouse_up && ./bin/plugin-server' diff --git a/bin/start-celery b/bin/start-celery new file mode 100755 index 0000000000000..ffefe0298e296 --- /dev/null +++ b/bin/start-celery @@ -0,0 +1,9 @@ +#!/bin/bash +# Starts a celery worker / heartbeat job. Must be run with a type of process: worker | beat + +set -e + +source ./bin/celery-queues.env + +# start celery worker with heartbeat (-B) +python manage.py run_autoreload_celery --type=$1