use gunicorn for prod api

This commit is contained in:
Shihaam Abdul Rahman 2024-10-19 04:23:11 +05:00
parent 3dda493315
commit 73eee65323
Signed by: shihaam
GPG Key ID: 6DA2E87EBC227636
2 changed files with 2 additions and 2 deletions

View File

@ -1,10 +1,10 @@
FROM python:3.9.20-slim-bookworm
RUN pip install python-dotenv flask
RUN pip install python-dotenv flask gunicorn
RUN apt-get update && apt-get install -y curl && apt-get clean && rm -rf /var/lib/apt/lists/*
WORKDIR /app
COPY api.py tx.sh .
RUN chmod +x tx.sh api.py
CMD ./api.py
CMD gunicorn --workers 4 --bind 0.0.0.0:5000 api:app

Binary file not shown.