mirror of
https://github.com/BerriAI/litellm.git
synced 2025-04-25 02:34:29 +00:00
15 lines
324 B
Python
15 lines
324 B
Python
import os
|
|
from multiprocessing import Process
|
|
|
|
|
|
def run_worker(cwd):
|
|
os.chdir(cwd)
|
|
os.system(
|
|
"celery -A celery_app.celery_app worker --concurrency=120 --loglevel=info"
|
|
)
|
|
|
|
|
|
def start_worker(cwd):
|
|
cwd += "/queue"
|
|
worker_process = Process(target=run_worker, args=(cwd,))
|
|
worker_process.start()
|