Skip to content

Commit 666980d

Browse files
committed
Update pip to use Python3 for PHP >= 7.3
1 parent b776a91 commit 666980d

5 files changed

Lines changed: 86 additions & 9 deletions

File tree

Dockerfiles/work/Dockerfile-7.3

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -158,11 +158,12 @@ RUN set -eux \
158158
# -------------------- pip --------------------
159159
&& DEBIAN_FRONTEND=noninteractive apt-get update -qq \
160160
&& DEBIAN_FRONTEND=noninteractive apt-get install -qq -y --no-install-recommends --no-install-suggests \
161-
libpython-dev \
161+
libpython3-dev \
162+
python3-distutils \
162163
&& DEBIAN_FRONTEND=noninteractive apt-get purge -qq -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false \
163164
&& rm -rf /var/lib/apt/lists/* \
164165
\
165-
&& curl -sS -L --fail https://bootstrap.pypa.io/pip/2.7/get-pip.py | python \
166+
&& curl -sS -L --fail https://bootstrap.pypa.io/get-pip.py | python3 \
166167
\
167168
\
168169
# -------------------- nvm --------------------

Dockerfiles/work/Dockerfile-7.4

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -158,11 +158,12 @@ RUN set -eux \
158158
# -------------------- pip --------------------
159159
&& DEBIAN_FRONTEND=noninteractive apt-get update -qq \
160160
&& DEBIAN_FRONTEND=noninteractive apt-get install -qq -y --no-install-recommends --no-install-suggests \
161-
libpython-dev \
161+
libpython3-dev \
162+
python3-distutils \
162163
&& DEBIAN_FRONTEND=noninteractive apt-get purge -qq -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false \
163164
&& rm -rf /var/lib/apt/lists/* \
164165
\
165-
&& curl -sS -L --fail https://bootstrap.pypa.io/pip/2.7/get-pip.py | python \
166+
&& curl -sS -L --fail https://bootstrap.pypa.io/get-pip.py | python3 \
166167
\
167168
\
168169
# -------------------- nvm --------------------

Dockerfiles/work/Dockerfile-8.0

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -158,11 +158,12 @@ RUN set -eux \
158158
# -------------------- pip --------------------
159159
&& DEBIAN_FRONTEND=noninteractive apt-get update -qq \
160160
&& DEBIAN_FRONTEND=noninteractive apt-get install -qq -y --no-install-recommends --no-install-suggests \
161-
libpython-dev \
161+
libpython3-dev \
162+
python3-distutils \
162163
&& DEBIAN_FRONTEND=noninteractive apt-get purge -qq -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false \
163164
&& rm -rf /var/lib/apt/lists/* \
164165
\
165-
&& curl -sS -L --fail https://bootstrap.pypa.io/pip/2.7/get-pip.py | python \
166+
&& curl -sS -L --fail https://bootstrap.pypa.io/get-pip.py | python3 \
166167
\
167168
\
168169
# -------------------- nvm --------------------

Dockerfiles/work/Dockerfile-8.1

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -158,11 +158,12 @@ RUN set -eux \
158158
# -------------------- pip --------------------
159159
&& DEBIAN_FRONTEND=noninteractive apt-get update -qq \
160160
&& DEBIAN_FRONTEND=noninteractive apt-get install -qq -y --no-install-recommends --no-install-suggests \
161-
libpython-dev \
161+
libpython3-dev \
162+
python3-distutils \
162163
&& DEBIAN_FRONTEND=noninteractive apt-get purge -qq -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false \
163164
&& rm -rf /var/lib/apt/lists/* \
164165
\
165-
&& curl -sS -L --fail https://bootstrap.pypa.io/pip/2.7/get-pip.py | python \
166+
&& curl -sS -L --fail https://bootstrap.pypa.io/get-pip.py | python3 \
166167
\
167168
\
168169
# -------------------- nvm --------------------

build/ansible/group_vars/all/work.yml

Lines changed: 74 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -422,7 +422,70 @@ software_available:
422422
&& ln -sf /usr/local/bin/composer-2 /usr/local/bin/composer \
423423
# pip is a dependency for others
424424
pip:
425-
all:
425+
5.2:
426+
command: |
427+
DEBIAN_FRONTEND=noninteractive apt-get update -qq \
428+
&& DEBIAN_FRONTEND=noninteractive apt-get install -qq -y --no-install-recommends --no-install-suggests \
429+
libpython-dev \
430+
&& DEBIAN_FRONTEND=noninteractive apt-get purge -qq -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false \
431+
&& rm -rf /var/lib/apt/lists/* \
432+
\
433+
&& curl -sS -L --fail https://bootstrap.pypa.io/pip/2.7/get-pip.py | python \
434+
5.3:
435+
command: |
436+
DEBIAN_FRONTEND=noninteractive apt-get update -qq \
437+
&& DEBIAN_FRONTEND=noninteractive apt-get install -qq -y --no-install-recommends --no-install-suggests \
438+
libpython-dev \
439+
&& DEBIAN_FRONTEND=noninteractive apt-get purge -qq -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false \
440+
&& rm -rf /var/lib/apt/lists/* \
441+
\
442+
&& curl -sS -L --fail https://bootstrap.pypa.io/pip/2.7/get-pip.py | python \
443+
5.4:
444+
command: |
445+
DEBIAN_FRONTEND=noninteractive apt-get update -qq \
446+
&& DEBIAN_FRONTEND=noninteractive apt-get install -qq -y --no-install-recommends --no-install-suggests \
447+
libpython-dev \
448+
&& DEBIAN_FRONTEND=noninteractive apt-get purge -qq -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false \
449+
&& rm -rf /var/lib/apt/lists/* \
450+
\
451+
&& curl -sS -L --fail https://bootstrap.pypa.io/pip/2.7/get-pip.py | python \
452+
5.5:
453+
command: |
454+
DEBIAN_FRONTEND=noninteractive apt-get update -qq \
455+
&& DEBIAN_FRONTEND=noninteractive apt-get install -qq -y --no-install-recommends --no-install-suggests \
456+
libpython-dev \
457+
&& DEBIAN_FRONTEND=noninteractive apt-get purge -qq -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false \
458+
&& rm -rf /var/lib/apt/lists/* \
459+
\
460+
&& curl -sS -L --fail https://bootstrap.pypa.io/pip/2.7/get-pip.py | python \
461+
5.6:
462+
command: |
463+
DEBIAN_FRONTEND=noninteractive apt-get update -qq \
464+
&& DEBIAN_FRONTEND=noninteractive apt-get install -qq -y --no-install-recommends --no-install-suggests \
465+
libpython-dev \
466+
&& DEBIAN_FRONTEND=noninteractive apt-get purge -qq -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false \
467+
&& rm -rf /var/lib/apt/lists/* \
468+
\
469+
&& curl -sS -L --fail https://bootstrap.pypa.io/pip/2.7/get-pip.py | python \
470+
7.0:
471+
command: |
472+
DEBIAN_FRONTEND=noninteractive apt-get update -qq \
473+
&& DEBIAN_FRONTEND=noninteractive apt-get install -qq -y --no-install-recommends --no-install-suggests \
474+
libpython-dev \
475+
&& DEBIAN_FRONTEND=noninteractive apt-get purge -qq -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false \
476+
&& rm -rf /var/lib/apt/lists/* \
477+
\
478+
&& curl -sS -L --fail https://bootstrap.pypa.io/pip/2.7/get-pip.py | python \
479+
7.1:
480+
command: |
481+
DEBIAN_FRONTEND=noninteractive apt-get update -qq \
482+
&& DEBIAN_FRONTEND=noninteractive apt-get install -qq -y --no-install-recommends --no-install-suggests \
483+
libpython-dev \
484+
&& DEBIAN_FRONTEND=noninteractive apt-get purge -qq -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false \
485+
&& rm -rf /var/lib/apt/lists/* \
486+
\
487+
&& curl -sS -L --fail https://bootstrap.pypa.io/pip/2.7/get-pip.py | python \
488+
7.2:
426489
command: |
427490
DEBIAN_FRONTEND=noninteractive apt-get update -qq \
428491
&& DEBIAN_FRONTEND=noninteractive apt-get install -qq -y --no-install-recommends --no-install-suggests \
@@ -431,6 +494,16 @@ software_available:
431494
&& rm -rf /var/lib/apt/lists/* \
432495
\
433496
&& curl -sS -L --fail https://bootstrap.pypa.io/pip/2.7/get-pip.py | python \
497+
all:
498+
command: |
499+
DEBIAN_FRONTEND=noninteractive apt-get update -qq \
500+
&& DEBIAN_FRONTEND=noninteractive apt-get install -qq -y --no-install-recommends --no-install-suggests \
501+
libpython3-dev \
502+
python3-distutils \
503+
&& DEBIAN_FRONTEND=noninteractive apt-get purge -qq -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false \
504+
&& rm -rf /var/lib/apt/lists/* \
505+
\
506+
&& curl -sS -L --fail https://bootstrap.pypa.io/get-pip.py | python3 \
434507
# nvm is a dependency for others
435508
nvm:
436509
check: su -c '. /opt/nvm/nvm.sh; nvm --version' devilbox | grep -E '^[0-9][.0-9]+'

0 commit comments

Comments
 (0)