mirror of
https://github.com/BerriAI/litellm.git
synced 2025-04-27 11:43:54 +00:00
v0 num_workers
This commit is contained in:
parent
3297b8ac0c
commit
b3de8e8fa2
1 changed files with 2 additions and 0 deletions
|
@ -472,6 +472,8 @@ def run_server(
|
||||||
# gunicorn app function
|
# gunicorn app function
|
||||||
return self.application
|
return self.application
|
||||||
|
|
||||||
|
# before starting server, read num_workers as an env variable
|
||||||
|
num_workers = os.getenv("NUM_WORKERS", num_workers)
|
||||||
gunicorn_options = {
|
gunicorn_options = {
|
||||||
"bind": f"{host}:{port}",
|
"bind": f"{host}:{port}",
|
||||||
"workers": num_workers, # default is 1
|
"workers": num_workers, # default is 1
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue