Skip to content

Commit 0c7fdb4

Browse files
committed
optionally specify more than 1 worker
1 parent cb2ee59 commit 0c7fdb4

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

bioindex/main.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,11 +65,13 @@ def cli(ctx, env_file):
6565

6666
@click.command(name='serve')
6767
@click.option('--port', '-p', type=int, default=5000)
68-
def cli_serve(port):
68+
@click.option('--workers', '-w', type=int, default=1)
69+
def cli_serve(port, workers):
6970
uvicorn.run(
7071
'bioindex.server:app',
7172
host='0.0.0.0',
7273
port=port,
74+
workers=workers,
7375
log_level='info',
7476
log_config=SERVER_LOGGING_CONFIG
7577
)

0 commit comments

Comments
 (0)