summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRazCrimson <52282402+RazCrimson@users.noreply.github.com>2023-05-14 01:54:10 +0530
committerGitHub <noreply@github.com>2023-05-14 01:54:10 +0530
commit6bd7c067f51809867ed5629ed9a6b0b1e8e912c3 (patch)
treec000738ccf4dce437a3b5528ec2f5ec0e9ecaaec
parent13f6db08bc6c9023e44d9635d69e09b2cf2a51bb (diff)
parent31d6338b9de68e09b539187bfa0ebfa477d10209 (diff)
Merge pull request #2395 from nicolargo/issue2392
Fix: missing `packaging` dependency with the new Dockerfile Closes: 2392
-rw-r--r--docker-files/alpine.Dockerfile7
-rw-r--r--docker-files/ubuntu.Dockerfile7
2 files changed, 8 insertions, 6 deletions
diff --git a/docker-files/alpine.Dockerfile b/docker-files/alpine.Dockerfile
index 768cf187..2497a438 100644
--- a/docker-files/alpine.Dockerfile
+++ b/docker-files/alpine.Dockerfile
@@ -50,7 +50,7 @@ RUN apk add --no-cache \
libffi-dev \
openssl-dev
-RUN python${PYTHON_VERSION} -m venv --system-site-packages --without-pip venv
+RUN python${PYTHON_VERSION} -m venv --without-pip venv
COPY requirements.txt docker-requirements.txt webui-requirements.txt optional-requirements.txt ./
@@ -58,7 +58,7 @@ COPY requirements.txt docker-requirements.txt webui-requirements.txt optional-re
# BUILD: Install the minimal image deps
FROM build as buildMinimal
-RUN /venv/bin/python3 -m pip install --no-cache-dir \
+RUN python${PYTHON_VERSION} -m pip install --target="/venv/lib/python${PYTHON_VERSION}/site-packages" \
# Note: requirements.txt is include by dep
-r docker-requirements.txt \
-r webui-requirements.txt
@@ -72,7 +72,8 @@ ARG CASS_DRIVER_NO_CYTHON=1
# See issue 2368
ARG CARGO_NET_GIT_FETCH_WITH_CLI=true
-RUN /venv/bin/python3 -m pip install --no-cache-dir \
+RUN python${PYTHON_VERSION} -m pip install --target="/venv/lib/python${PYTHON_VERSION}/site-packages" \
+ # Note: requirements.txt is include by dep
-r optional-requirements.txt
##############################################################################
diff --git a/docker-files/ubuntu.Dockerfile b/docker-files/ubuntu.Dockerfile
index 05186eaf..33771452 100644
--- a/docker-files/ubuntu.Dockerfile
+++ b/docker-files/ubuntu.Dockerfile
@@ -49,7 +49,7 @@ RUN apt-get update \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*
-RUN python${PYTHON_VERSION} -m venv venv
+RUN python${PYTHON_VERSION} -m venv --without-pip venv
COPY requirements.txt docker-requirements.txt webui-requirements.txt optional-requirements.txt ./
@@ -57,7 +57,7 @@ COPY requirements.txt docker-requirements.txt webui-requirements.txt optional-re
# BUILD: Install the minimal image deps
FROM build as buildMinimal
-RUN /venv/bin/python3 -m pip install --no-cache-dir \
+RUN python${PYTHON_VERSION} -m pip install --target="/venv/lib/python${PYTHON_VERSION}/site-packages" \
# Note: requirements.txt is include by dep
-r docker-requirements.txt \
-r webui-requirements.txt
@@ -66,7 +66,8 @@ RUN /venv/bin/python3 -m pip install --no-cache-dir \
# BUILD: Install all the deps
FROM build as buildFull
-RUN /venv/bin/python3 -m pip install --no-cache-dir \
+RUN python${PYTHON_VERSION} -m pip install --target="/venv/lib/python${PYTHON_VERSION}/site-packages" \
+ # Note: requirements.txt is include by dep
-r optional-requirements.txt
##############################################################################