Improve Dockerfile:

- Use smaller base image
- Make it smaller by not saving cache (1,15GB -> 356MB)
This commit is contained in:
Kiss Péter
2023-04-11 14:04:37 +02:00
parent 186a8c615e
commit 739b0ed96b

View File

@@ -1,9 +1,7 @@
FROM python:3.11
FROM python:3.11-slim
ENV PIP_NO_CACHE_DIR=yes
WORKDIR /app
COPY scripts/ /app
COPY requirements.txt /app
COPY requirements.txt .
RUN pip install -r requirements.txt
CMD ["python", "main.py"]
COPY scripts/ .
ENTRYPOINT ["python", "main.py"]