Skip to content

Commit 98cf165

Browse files
committed
migrate from poetry to ry
1 parent 29a96de commit 98cf165

6 files changed

Lines changed: 190 additions & 1274 deletions

File tree

.env-sample

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ DATABASE_USER="dbuser"
33
DATABASE_PASSWORD="dbpass"
44
DATABASE_SERVER="db"
55
DATABASE_DB="dbname"
6+
DATABSE_LOCATION="db.sqlite"
67
# Optional (make them comment to use default values)
78
LOG_LEVEL="ERROR" # DEBUG, INFO, WARNING, ERROR, CRITICAL
89
LOGGING_FORMAT="{asctime} [{levelname}] - {name} : {message}"

Dockerfile

Lines changed: 3 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -1,35 +1,12 @@
11
# pull base image
22
FROM python:3.11
33

4-
# Set Environment variables
5-
ENV PYTHONDONTWRITEBYTECODE 1
6-
ENV PYTHONUNBUFFERED 1
7-
# Configure Poetry
8-
ENV POETRY_VERSION=1.6.1
9-
ENV POETRY_NO_INTERACTION=1
10-
ENV POETRY_VIRTUALENVS_CREATE=false
11-
ENV POETRY_CACHE_DIR='/var/cache/pypoetry'
12-
ENV POETRY_HOME='/usr/local'
13-
14-
154
WORKDIR /code/
165

6+
RUN pip install uv
177

18-
# Install Poetry
19-
# https://github.com/python-poetry/poetry
20-
RUN curl -sSL 'https://install.python-poetry.org' | python - \
21-
&& poetry --version
22-
23-
24-
# Add `poetry` to PATH
25-
ENV PATH="${PATH}:${POETRY_VENV}/bin"
26-
27-
# install the dependencies
28-
COPY poetry.lock pyproject.toml ./
29-
30-
# Allow installing dev dependencies to run tests
31-
ARG INSTALL_DEV=false
32-
RUN bash -c "if [ $INSTALL_DEV == 'true' ] ; then poetry install --no-root ; else poetry install --no-dev --no-root ; fi"
8+
COPY requirements.lock ./
9+
RUN uv pip install --no-cache --system -r requirements.lock
3310

3411
COPY . ./
3512

0 commit comments

Comments
 (0)