neues dockerfile mit gunicorn Server
This commit is contained in:
12
Dockerfile
12
Dockerfile
@@ -1,12 +1,16 @@
|
||||
FROM python:3.12-slim
|
||||
FROM python:3.13-slim
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
COPY requirements.txt ./
|
||||
RUN pip install --no-cache-dir -r requirements.txt
|
||||
COPY requirements.txt .
|
||||
RUN pip install --no-cache-dir -r requirements.txt gunicorn
|
||||
|
||||
COPY . .
|
||||
|
||||
RUN addgroup --system app && adduser --system --ingroup app app && \
|
||||
chown -R app:app /app
|
||||
USER app
|
||||
|
||||
EXPOSE 5005
|
||||
|
||||
CMD ["python", "app.py"]
|
||||
CMD ["gunicorn", "-b", "0.0.0.0:5005", "-w", "4", "app:app"]
|
||||
|
||||
Reference in New Issue
Block a user