Skip to content

Commit

Permalink
Use poetry base image
Browse files Browse the repository at this point in the history
  • Loading branch information
ChrisLovering committed Sep 23, 2022
1 parent 2362cae commit 49a2922
Showing 1 changed file with 6 additions and 9 deletions.
15 changes: 6 additions & 9 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,13 +1,10 @@
FROM --platform=linux/amd64 python:3.9-slim-buster
FROM --platform=linux/amd64 ghcr.io/chrislovering/python-poetry-base:3.10-slim

WORKDIR /app
COPY pyproject.toml poetry.lock ./
RUN poetry install --without dev

RUN pip install poetry
COPY . .

COPY pyproject.toml /app/pyproject.toml

RUN poetry install --no-dev

COPY . /app

CMD ["poetry", "run", "uvicorn", "api.main:app", "--host", "0.0.0.0", "--port", "80"]
ENTRYPOINT ["poetry"]
CMD ["run", "uvicorn", "api.main:app", "--host", "0.0.0.0", "--port", "80"]

0 comments on commit 49a2922

Please sign in to comment.