From 2a0f0314648e7d12d2e28583205627683ebd68dd Mon Sep 17 00:00:00 2001 From: root Date: Fri, 22 Nov 2024 09:05:08 +0000 Subject: [PATCH] Modify service Dockerfile as no longer require developer stage --- .devcontainer/Dockerfile | 2 +- Dockerfile | 6 +----- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/.devcontainer/Dockerfile b/.devcontainer/Dockerfile index 2dfc0eab4..35d2abf7a 100644 --- a/.devcontainer/Dockerfile +++ b/.devcontainer/Dockerfile @@ -10,4 +10,4 @@ RUN apt-get update && apt-get install -y --no-install-recommends \ # Set up a virtual environment and put it in PATH RUN python -m venv /venv -ENV PATH=/venv/bin:$PATH \ No newline at end of file +ENV PATH=/venv/bin:$PATH diff --git a/Dockerfile b/Dockerfile index 06b988263..74591f73a 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,7 +1,5 @@ -# The devcontainer should use the developer target and run as root with podman -# or docker with user namespaces. ARG PYTHON_VERSION=3.11 -FROM python:${PYTHON_VERSION} AS developer +FROM python:${PYTHON_VERSION} AS build # Add any system dependencies for the developer/build environment here RUN apt-get update && apt-get install -y --no-install-recommends \ @@ -12,8 +10,6 @@ RUN apt-get update && apt-get install -y --no-install-recommends \ RUN python -m venv /venv ENV PATH=/venv/bin:$PATH -# The build stage installs the context into the venv -FROM developer AS build COPY . /context WORKDIR /context RUN touch dev-requirements.txt && pip install --upgrade pip && pip install -c dev-requirements.txt .