alexandraroze commited on
Commit
f33e28a
·
1 Parent(s): 5a53d59

updated dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +2 -2
Dockerfile CHANGED
@@ -3,6 +3,7 @@ FROM python:3.10
3
  RUN useradd -m -u 1000 user
4
  USER user
5
  ENV PATH="/home/user/.local/bin:$PATH"
 
6
 
7
  # Set the working directory to a writable location
8
  WORKDIR /home/user/app
@@ -15,8 +16,7 @@ RUN pip install --no-cache-dir --upgrade pip \
15
  COPY --chown=user ./pyproject.toml ./poetry.lock* ./
16
 
17
  # Install dependencies with Poetry
18
- RUN poetry config virtualenvs.create false \
19
- && poetry install --no-dev --no-interaction --no-ansi
20
 
21
  # Copy the rest of the application code
22
  COPY --chown=user . /home/user/app
 
3
  RUN useradd -m -u 1000 user
4
  USER user
5
  ENV PATH="/home/user/.local/bin:$PATH"
6
+ ENV POETRY_CACHE_DIR=/home/user/.cache/pypoetry
7
 
8
  # Set the working directory to a writable location
9
  WORKDIR /home/user/app
 
16
  COPY --chown=user ./pyproject.toml ./poetry.lock* ./
17
 
18
  # Install dependencies with Poetry
19
+ RUN poetry install --only main --no-interaction --no-ansi
 
20
 
21
  # Copy the rest of the application code
22
  COPY --chown=user . /home/user/app