mirror of
https://github.com/tropicoo/yt-dlp-bot.git
synced 2024-09-20 06:46:08 +08:00
Add api workers config value
This commit is contained in:
parent
d4297ec82a
commit
4777855e29
|
@ -1,11 +1,11 @@
|
|||
import uvicorn
|
||||
|
||||
from api.core.app import app
|
||||
from api.core.app import app # noqa: F401
|
||||
from api.core.config import settings
|
||||
|
||||
if __name__ == '__main__':
|
||||
uvicorn.run(
|
||||
app,
|
||||
'main:app',
|
||||
host=settings.API_HOST,
|
||||
port=settings.API_PORT,
|
||||
workers=settings.API_WORKERS,
|
||||
|
|
|
@ -19,7 +19,7 @@ services:
|
|||
restart: unless-stopped
|
||||
ports:
|
||||
- "1984:8000"
|
||||
command: bash -c "python start.py && uvicorn main:app --host 0.0.0.0 --port 8000"
|
||||
command: bash -c "python start.py && python main.py"
|
||||
depends_on:
|
||||
- postgres
|
||||
- rabbitmq
|
||||
|
|
Loading…
Reference in a new issue