diff --git a/3.10/alpine3.14/Dockerfile b/3.10/alpine3.14/Dockerfile index 15209c949..f85b872b3 100644 --- a/3.10/alpine3.14/Dockerfile +++ b/3.10/alpine3.14/Dockerfile @@ -130,21 +130,17 @@ RUN set -eux; \ wget -O get-pip.py "$PYTHON_GET_PIP_URL"; \ echo "$PYTHON_GET_PIP_SHA256 *get-pip.py" | sha256sum -c -; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.10/alpine3.15/Dockerfile b/3.10/alpine3.15/Dockerfile index d63e6f3ff..89ed484a6 100644 --- a/3.10/alpine3.15/Dockerfile +++ b/3.10/alpine3.15/Dockerfile @@ -130,21 +130,17 @@ RUN set -eux; \ wget -O get-pip.py "$PYTHON_GET_PIP_URL"; \ echo "$PYTHON_GET_PIP_SHA256 *get-pip.py" | sha256sum -c -; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.10/bullseye/Dockerfile b/3.10/bullseye/Dockerfile index 331d9e488..8ab270e62 100644 --- a/3.10/bullseye/Dockerfile +++ b/3.10/bullseye/Dockerfile @@ -92,21 +92,17 @@ RUN set -eux; \ wget -O get-pip.py "$PYTHON_GET_PIP_URL"; \ echo "$PYTHON_GET_PIP_SHA256 *get-pip.py" | sha256sum -c -; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.10/buster/Dockerfile b/3.10/buster/Dockerfile index 1854da855..ec3e19609 100644 --- a/3.10/buster/Dockerfile +++ b/3.10/buster/Dockerfile @@ -92,21 +92,17 @@ RUN set -eux; \ wget -O get-pip.py "$PYTHON_GET_PIP_URL"; \ echo "$PYTHON_GET_PIP_SHA256 *get-pip.py" | sha256sum -c -; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.10/slim-bullseye/Dockerfile b/3.10/slim-bullseye/Dockerfile index 60297b6dc..9ef1a1878 100644 --- a/3.10/slim-bullseye/Dockerfile +++ b/3.10/slim-bullseye/Dockerfile @@ -140,21 +140,17 @@ RUN set -eux; \ apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \ rm -rf /var/lib/apt/lists/*; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.10/slim-buster/Dockerfile b/3.10/slim-buster/Dockerfile index 908631430..94d14c392 100644 --- a/3.10/slim-buster/Dockerfile +++ b/3.10/slim-buster/Dockerfile @@ -140,21 +140,17 @@ RUN set -eux; \ apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \ rm -rf /var/lib/apt/lists/*; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.10/windows/windowsservercore-1809/Dockerfile b/3.10/windows/windowsservercore-1809/Dockerfile index 834e1d317..718f34181 100644 --- a/3.10/windows/windowsservercore-1809/Dockerfile +++ b/3.10/windows/windowsservercore-1809/Dockerfile @@ -67,10 +67,13 @@ RUN Write-Host ('Downloading get-pip.py ({0}) ...' -f $env:PYTHON_GET_PIP_URL); exit 1; \ }; \ \ + $env:PYTHONDONTWRITEBYTECODE = '1'; \ + \ Write-Host ('Installing pip=={0} ...' -f $env:PYTHON_PIP_VERSION); \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ ('pip=={0}' -f $env:PYTHON_PIP_VERSION) \ ('setuptools=={0}' -f $env:PYTHON_SETUPTOOLS_VERSION) \ ; \ diff --git a/3.10/windows/windowsservercore-ltsc2022/Dockerfile b/3.10/windows/windowsservercore-ltsc2022/Dockerfile index 891a79607..6dda5e204 100644 --- a/3.10/windows/windowsservercore-ltsc2022/Dockerfile +++ b/3.10/windows/windowsservercore-ltsc2022/Dockerfile @@ -67,10 +67,13 @@ RUN Write-Host ('Downloading get-pip.py ({0}) ...' -f $env:PYTHON_GET_PIP_URL); exit 1; \ }; \ \ + $env:PYTHONDONTWRITEBYTECODE = '1'; \ + \ Write-Host ('Installing pip=={0} ...' -f $env:PYTHON_PIP_VERSION); \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ ('pip=={0}' -f $env:PYTHON_PIP_VERSION) \ ('setuptools=={0}' -f $env:PYTHON_SETUPTOOLS_VERSION) \ ; \ diff --git a/3.11-rc/alpine3.14/Dockerfile b/3.11-rc/alpine3.14/Dockerfile index a302d845b..5bcb344f2 100644 --- a/3.11-rc/alpine3.14/Dockerfile +++ b/3.11-rc/alpine3.14/Dockerfile @@ -130,21 +130,17 @@ RUN set -eux; \ wget -O get-pip.py "$PYTHON_GET_PIP_URL"; \ echo "$PYTHON_GET_PIP_SHA256 *get-pip.py" | sha256sum -c -; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.11-rc/alpine3.15/Dockerfile b/3.11-rc/alpine3.15/Dockerfile index 4bde5f810..c66ee6cae 100644 --- a/3.11-rc/alpine3.15/Dockerfile +++ b/3.11-rc/alpine3.15/Dockerfile @@ -130,21 +130,17 @@ RUN set -eux; \ wget -O get-pip.py "$PYTHON_GET_PIP_URL"; \ echo "$PYTHON_GET_PIP_SHA256 *get-pip.py" | sha256sum -c -; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.11-rc/bullseye/Dockerfile b/3.11-rc/bullseye/Dockerfile index 05348e501..d079ee69e 100644 --- a/3.11-rc/bullseye/Dockerfile +++ b/3.11-rc/bullseye/Dockerfile @@ -92,21 +92,17 @@ RUN set -eux; \ wget -O get-pip.py "$PYTHON_GET_PIP_URL"; \ echo "$PYTHON_GET_PIP_SHA256 *get-pip.py" | sha256sum -c -; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.11-rc/buster/Dockerfile b/3.11-rc/buster/Dockerfile index 6adac4d57..6675540a3 100644 --- a/3.11-rc/buster/Dockerfile +++ b/3.11-rc/buster/Dockerfile @@ -92,21 +92,17 @@ RUN set -eux; \ wget -O get-pip.py "$PYTHON_GET_PIP_URL"; \ echo "$PYTHON_GET_PIP_SHA256 *get-pip.py" | sha256sum -c -; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.11-rc/slim-bullseye/Dockerfile b/3.11-rc/slim-bullseye/Dockerfile index 64395d3b4..3e57b8cb5 100644 --- a/3.11-rc/slim-bullseye/Dockerfile +++ b/3.11-rc/slim-bullseye/Dockerfile @@ -140,21 +140,17 @@ RUN set -eux; \ apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \ rm -rf /var/lib/apt/lists/*; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.11-rc/slim-buster/Dockerfile b/3.11-rc/slim-buster/Dockerfile index 4a359d9f8..d12376134 100644 --- a/3.11-rc/slim-buster/Dockerfile +++ b/3.11-rc/slim-buster/Dockerfile @@ -140,21 +140,17 @@ RUN set -eux; \ apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \ rm -rf /var/lib/apt/lists/*; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.11-rc/windows/windowsservercore-1809/Dockerfile b/3.11-rc/windows/windowsservercore-1809/Dockerfile index 8de824847..dafe215d2 100644 --- a/3.11-rc/windows/windowsservercore-1809/Dockerfile +++ b/3.11-rc/windows/windowsservercore-1809/Dockerfile @@ -67,10 +67,13 @@ RUN Write-Host ('Downloading get-pip.py ({0}) ...' -f $env:PYTHON_GET_PIP_URL); exit 1; \ }; \ \ + $env:PYTHONDONTWRITEBYTECODE = '1'; \ + \ Write-Host ('Installing pip=={0} ...' -f $env:PYTHON_PIP_VERSION); \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ ('pip=={0}' -f $env:PYTHON_PIP_VERSION) \ ('setuptools=={0}' -f $env:PYTHON_SETUPTOOLS_VERSION) \ ; \ diff --git a/3.11-rc/windows/windowsservercore-ltsc2022/Dockerfile b/3.11-rc/windows/windowsservercore-ltsc2022/Dockerfile index fcbb27291..841d8abc8 100644 --- a/3.11-rc/windows/windowsservercore-ltsc2022/Dockerfile +++ b/3.11-rc/windows/windowsservercore-ltsc2022/Dockerfile @@ -67,10 +67,13 @@ RUN Write-Host ('Downloading get-pip.py ({0}) ...' -f $env:PYTHON_GET_PIP_URL); exit 1; \ }; \ \ + $env:PYTHONDONTWRITEBYTECODE = '1'; \ + \ Write-Host ('Installing pip=={0} ...' -f $env:PYTHON_PIP_VERSION); \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ ('pip=={0}' -f $env:PYTHON_PIP_VERSION) \ ('setuptools=={0}' -f $env:PYTHON_SETUPTOOLS_VERSION) \ ; \ diff --git a/3.7/alpine3.14/Dockerfile b/3.7/alpine3.14/Dockerfile index 230645a73..b73d0efb8 100644 --- a/3.7/alpine3.14/Dockerfile +++ b/3.7/alpine3.14/Dockerfile @@ -166,21 +166,17 @@ RUN set -eux; \ wget -O get-pip.py "$PYTHON_GET_PIP_URL"; \ echo "$PYTHON_GET_PIP_SHA256 *get-pip.py" | sha256sum -c -; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.7/alpine3.15/Dockerfile b/3.7/alpine3.15/Dockerfile index 383e43f3e..cf044b0fc 100644 --- a/3.7/alpine3.15/Dockerfile +++ b/3.7/alpine3.15/Dockerfile @@ -166,21 +166,17 @@ RUN set -eux; \ wget -O get-pip.py "$PYTHON_GET_PIP_URL"; \ echo "$PYTHON_GET_PIP_SHA256 *get-pip.py" | sha256sum -c -; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.7/bullseye/Dockerfile b/3.7/bullseye/Dockerfile index 08d0fada3..5b8ae4cf6 100644 --- a/3.7/bullseye/Dockerfile +++ b/3.7/bullseye/Dockerfile @@ -128,21 +128,17 @@ RUN set -eux; \ wget -O get-pip.py "$PYTHON_GET_PIP_URL"; \ echo "$PYTHON_GET_PIP_SHA256 *get-pip.py" | sha256sum -c -; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.7/buster/Dockerfile b/3.7/buster/Dockerfile index 8a5159625..ab61ffd35 100644 --- a/3.7/buster/Dockerfile +++ b/3.7/buster/Dockerfile @@ -128,21 +128,17 @@ RUN set -eux; \ wget -O get-pip.py "$PYTHON_GET_PIP_URL"; \ echo "$PYTHON_GET_PIP_SHA256 *get-pip.py" | sha256sum -c -; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.7/slim-bullseye/Dockerfile b/3.7/slim-bullseye/Dockerfile index 6e74c474c..ec9aa1bfc 100644 --- a/3.7/slim-bullseye/Dockerfile +++ b/3.7/slim-bullseye/Dockerfile @@ -176,21 +176,17 @@ RUN set -eux; \ apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \ rm -rf /var/lib/apt/lists/*; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.7/slim-buster/Dockerfile b/3.7/slim-buster/Dockerfile index 06d65a70c..f4d7dbaa9 100644 --- a/3.7/slim-buster/Dockerfile +++ b/3.7/slim-buster/Dockerfile @@ -176,21 +176,17 @@ RUN set -eux; \ apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \ rm -rf /var/lib/apt/lists/*; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.8/alpine3.14/Dockerfile b/3.8/alpine3.14/Dockerfile index cf46db753..aa161cd84 100644 --- a/3.8/alpine3.14/Dockerfile +++ b/3.8/alpine3.14/Dockerfile @@ -130,21 +130,17 @@ RUN set -eux; \ wget -O get-pip.py "$PYTHON_GET_PIP_URL"; \ echo "$PYTHON_GET_PIP_SHA256 *get-pip.py" | sha256sum -c -; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.8/alpine3.15/Dockerfile b/3.8/alpine3.15/Dockerfile index 6db3deb7c..71e15cd1c 100644 --- a/3.8/alpine3.15/Dockerfile +++ b/3.8/alpine3.15/Dockerfile @@ -130,21 +130,17 @@ RUN set -eux; \ wget -O get-pip.py "$PYTHON_GET_PIP_URL"; \ echo "$PYTHON_GET_PIP_SHA256 *get-pip.py" | sha256sum -c -; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.8/bullseye/Dockerfile b/3.8/bullseye/Dockerfile index eda4387c3..1d679337f 100644 --- a/3.8/bullseye/Dockerfile +++ b/3.8/bullseye/Dockerfile @@ -92,21 +92,17 @@ RUN set -eux; \ wget -O get-pip.py "$PYTHON_GET_PIP_URL"; \ echo "$PYTHON_GET_PIP_SHA256 *get-pip.py" | sha256sum -c -; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.8/buster/Dockerfile b/3.8/buster/Dockerfile index 4792cdaa0..75f2e907a 100644 --- a/3.8/buster/Dockerfile +++ b/3.8/buster/Dockerfile @@ -92,21 +92,17 @@ RUN set -eux; \ wget -O get-pip.py "$PYTHON_GET_PIP_URL"; \ echo "$PYTHON_GET_PIP_SHA256 *get-pip.py" | sha256sum -c -; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.8/slim-bullseye/Dockerfile b/3.8/slim-bullseye/Dockerfile index ce158a060..32a2aff49 100644 --- a/3.8/slim-bullseye/Dockerfile +++ b/3.8/slim-bullseye/Dockerfile @@ -140,21 +140,17 @@ RUN set -eux; \ apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \ rm -rf /var/lib/apt/lists/*; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.8/slim-buster/Dockerfile b/3.8/slim-buster/Dockerfile index 1de34f919..b56ab50b5 100644 --- a/3.8/slim-buster/Dockerfile +++ b/3.8/slim-buster/Dockerfile @@ -140,21 +140,17 @@ RUN set -eux; \ apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \ rm -rf /var/lib/apt/lists/*; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.9/alpine3.14/Dockerfile b/3.9/alpine3.14/Dockerfile index 4185d578e..b7ed6e7b9 100644 --- a/3.9/alpine3.14/Dockerfile +++ b/3.9/alpine3.14/Dockerfile @@ -129,21 +129,17 @@ RUN set -eux; \ wget -O get-pip.py "$PYTHON_GET_PIP_URL"; \ echo "$PYTHON_GET_PIP_SHA256 *get-pip.py" | sha256sum -c -; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.9/alpine3.15/Dockerfile b/3.9/alpine3.15/Dockerfile index fb5babb58..4c16ba521 100644 --- a/3.9/alpine3.15/Dockerfile +++ b/3.9/alpine3.15/Dockerfile @@ -129,21 +129,17 @@ RUN set -eux; \ wget -O get-pip.py "$PYTHON_GET_PIP_URL"; \ echo "$PYTHON_GET_PIP_SHA256 *get-pip.py" | sha256sum -c -; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.9/bullseye/Dockerfile b/3.9/bullseye/Dockerfile index d2fb4dde0..c0c317a24 100644 --- a/3.9/bullseye/Dockerfile +++ b/3.9/bullseye/Dockerfile @@ -91,21 +91,17 @@ RUN set -eux; \ wget -O get-pip.py "$PYTHON_GET_PIP_URL"; \ echo "$PYTHON_GET_PIP_SHA256 *get-pip.py" | sha256sum -c -; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.9/buster/Dockerfile b/3.9/buster/Dockerfile index 0fa56c72d..286c0fa79 100644 --- a/3.9/buster/Dockerfile +++ b/3.9/buster/Dockerfile @@ -91,21 +91,17 @@ RUN set -eux; \ wget -O get-pip.py "$PYTHON_GET_PIP_URL"; \ echo "$PYTHON_GET_PIP_SHA256 *get-pip.py" | sha256sum -c -; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.9/slim-bullseye/Dockerfile b/3.9/slim-bullseye/Dockerfile index 6c670296e..5948c8216 100644 --- a/3.9/slim-bullseye/Dockerfile +++ b/3.9/slim-bullseye/Dockerfile @@ -139,21 +139,17 @@ RUN set -eux; \ apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \ rm -rf /var/lib/apt/lists/*; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.9/slim-buster/Dockerfile b/3.9/slim-buster/Dockerfile index 83d160d02..c263d8639 100644 --- a/3.9/slim-buster/Dockerfile +++ b/3.9/slim-buster/Dockerfile @@ -139,21 +139,17 @@ RUN set -eux; \ apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \ rm -rf /var/lib/apt/lists/*; \ \ + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/3.9/windows/windowsservercore-1809/Dockerfile b/3.9/windows/windowsservercore-1809/Dockerfile index e2b467dbe..c245ba010 100644 --- a/3.9/windows/windowsservercore-1809/Dockerfile +++ b/3.9/windows/windowsservercore-1809/Dockerfile @@ -67,10 +67,13 @@ RUN Write-Host ('Downloading get-pip.py ({0}) ...' -f $env:PYTHON_GET_PIP_URL); exit 1; \ }; \ \ + $env:PYTHONDONTWRITEBYTECODE = '1'; \ + \ Write-Host ('Installing pip=={0} ...' -f $env:PYTHON_PIP_VERSION); \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ ('pip=={0}' -f $env:PYTHON_PIP_VERSION) \ ('setuptools=={0}' -f $env:PYTHON_SETUPTOOLS_VERSION) \ ; \ diff --git a/3.9/windows/windowsservercore-ltsc2022/Dockerfile b/3.9/windows/windowsservercore-ltsc2022/Dockerfile index d58a2188b..a709cc965 100644 --- a/3.9/windows/windowsservercore-ltsc2022/Dockerfile +++ b/3.9/windows/windowsservercore-ltsc2022/Dockerfile @@ -67,10 +67,13 @@ RUN Write-Host ('Downloading get-pip.py ({0}) ...' -f $env:PYTHON_GET_PIP_URL); exit 1; \ }; \ \ + $env:PYTHONDONTWRITEBYTECODE = '1'; \ + \ Write-Host ('Installing pip=={0} ...' -f $env:PYTHON_PIP_VERSION); \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ ('pip=={0}' -f $env:PYTHON_PIP_VERSION) \ ('setuptools=={0}' -f $env:PYTHON_SETUPTOOLS_VERSION) \ ; \ diff --git a/Dockerfile-linux.template b/Dockerfile-linux.template index 898b3e045..5a4b5cc52 100644 --- a/Dockerfile-linux.template +++ b/Dockerfile-linux.template @@ -302,21 +302,17 @@ RUN set -eux; \ rm -rf /var/lib/apt/lists/*; \ \ {{ ) else "" end -}} + export PYTHONDONTWRITEBYTECODE=1; \ + \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ "pip==$PYTHON_PIP_VERSION" \ "setuptools==$PYTHON_SETUPTOOLS_VERSION" \ ; \ - pip --version; \ + rm -f get-pip.py; \ \ - find /usr/local -depth \ - \( \ - \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) \ - -o \ - \( -type f -a \( -name '*.pyc' -o -name '*.pyo' \) \) \ - \) -exec rm -rf '{}' + \ - ; \ - rm -f get-pip.py + pip --version CMD ["python3"] diff --git a/Dockerfile-windows.template b/Dockerfile-windows.template index e9bff5b5a..556f6705e 100644 --- a/Dockerfile-windows.template +++ b/Dockerfile-windows.template @@ -61,10 +61,13 @@ RUN Write-Host ('Downloading get-pip.py ({0}) ...' -f $env:PYTHON_GET_PIP_URL); exit 1; \ }; \ \ + $env:PYTHONDONTWRITEBYTECODE = '1'; \ + \ Write-Host ('Installing pip=={0} ...' -f $env:PYTHON_PIP_VERSION); \ python get-pip.py \ --disable-pip-version-check \ --no-cache-dir \ + --no-compile \ ('pip=={0}' -f $env:PYTHON_PIP_VERSION) \ ('setuptools=={0}' -f $env:PYTHON_SETUPTOOLS_VERSION) \ ; \