Skip to content
This repository was archived by the owner on Nov 28, 2023. It is now read-only.

Commit 44194ee

Browse files
committed
Fix poetry
Based on fastapi#460 (comment)
1 parent 490c554 commit 44194ee

File tree

2 files changed

+6
-8
lines changed

2 files changed

+6
-8
lines changed

{{cookiecutter.project_slug}}/backend/backend.dockerfile

+3-4
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,9 @@ FROM tiangolo/uvicorn-gunicorn-fastapi:python3.7
33
WORKDIR /app/
44

55
# Install Poetry
6-
RUN curl -sSL https://raw.githubusercontent.com/python-poetry/poetry/master/get-poetry.py | POETRY_HOME=/opt/poetry python && \
7-
cd /usr/local/bin && \
8-
ln -s /opt/poetry/bin/poetry && \
9-
poetry config virtualenvs.create false
6+
RUN curl -sSL https://install.python-poetry.org | POETRY_HOME=/opt/poetry python3
7+
ENV PATH="/opt/poetry/bin:$PATH"
8+
RUN poetry config virtualenvs.create false
109

1110
# Copy poetry.lock* in case it doesn't exist in the repo
1211
COPY ./app/pyproject.toml ./app/poetry.lock* /app/

{{cookiecutter.project_slug}}/backend/celeryworker.dockerfile

+3-4
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,9 @@ FROM python:3.7
33
WORKDIR /app/
44

55
# Install Poetry
6-
RUN curl -sSL https://raw.githubusercontent.com/python-poetry/poetry/master/get-poetry.py | POETRY_HOME=/opt/poetry python && \
7-
cd /usr/local/bin && \
8-
ln -s /opt/poetry/bin/poetry && \
9-
poetry config virtualenvs.create false
6+
RUN curl -sSL https://install.python-poetry.org | POETRY_HOME=/opt/poetry python3
7+
ENV PATH="/opt/poetry/bin:$PATH"
8+
RUN poetry config virtualenvs.create false
109

1110
# Copy poetry.lock* in case it doesn't exist in the repo
1211
COPY ./app/pyproject.toml ./app/poetry.lock* /app/

0 commit comments

Comments
 (0)