-
Notifications
You must be signed in to change notification settings - Fork 291
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
8045a80
commit 5fbeef9
Showing
2 changed files
with
15 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,24 @@ | ||
ARG PYTHON_VERSION | ||
FROM python:${version}-slim-bookworm | ||
FROM python:${PYTHON_VERSION}-slim-bookworm | ||
|
||
WORKDIR /workspace | ||
RUN pip install --upgrade pip \ | ||
&& apt-get update \ | ||
&& apt-get install -y \ | ||
freetds-dev \ | ||
&& rm -rf /var/lib/apt/lists/* | ||
&& apt-get install -y freetds-dev \ | ||
&& apt-get install -y make \ | ||
# no real need for keeping this image small at the moment | ||
&& :; # rm -rf /var/lib/apt/lists/* | ||
|
||
# install requirements we exported from poetry | ||
COPY build/requirements.txt requirements.txt | ||
RUN pip install -r requirements.txt | ||
# install poetry | ||
RUN bash -c 'python -m venv /opt/poetry-venv && source $_/bin/activate && pip install poetry && ln -s $(which poetry) /usr/bin' | ||
|
||
# install dependencies with poetry | ||
COPY pyproject.toml . | ||
COPY poetry.lock . | ||
RUN poetry install --all-extras --with dev --no-root | ||
|
||
# copy project source | ||
COPY . . | ||
|
||
# install project with poetry | ||
RUN poetry install --all-extras --with dev |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters