From b7d33116490be4c06c0e5a50b63eeed7d9e66d1a Mon Sep 17 00:00:00 2001 From: Ahmad Mahmoudi Date: Wed, 17 Jun 2020 18:15:07 +0000 Subject: [PATCH] (fix) Changed pip to pip3 Changed pip to pip3 to address zuul gate issues. Change-Id: Id265b405b293af5b51b4774ca4c7465c9e9457b6 --- playbooks/osh-infra-bandit.yaml | 2 +- tools/gate/devel/start.sh | 18 +++++++++--------- tools/images/kubeadm-aio/Dockerfile | 8 ++++---- 3 files changed, 14 insertions(+), 14 deletions(-) diff --git a/playbooks/osh-infra-bandit.yaml b/playbooks/osh-infra-bandit.yaml index 5ed6a630a..65ee76d68 100644 --- a/playbooks/osh-infra-bandit.yaml +++ b/playbooks/osh-infra-bandit.yaml @@ -8,7 +8,7 @@ set -xe; ./tools/deployment/common/000-install-packages.sh ./tools/deployment/common/005-deploy-k8s.sh - sudo -H pip install yq bandit + sudo -H pip3 install yq bandit environment: zuul_site_mirror_fqdn: "{{ zuul_site_mirror_fqdn }}" args: diff --git a/tools/gate/devel/start.sh b/tools/gate/devel/start.sh index 9124f006b..e71043f59 100755 --- a/tools/gate/devel/start.sh +++ b/tools/gate/devel/start.sh @@ -26,9 +26,9 @@ function ansible_install { if [ "x$ID" == "xubuntu" ]; then sudo apt-get update -y sudo apt-get install -y --no-install-recommends \ - python-pip \ + python3-pip \ libssl-dev \ - python-dev \ + python3-dev \ build-essential \ jq \ curl @@ -36,7 +36,7 @@ function ansible_install { sudo yum install -y \ epel-release sudo yum install -y \ - python-pip \ + python3-pip \ python-devel \ redhat-rpm-config \ gcc \ @@ -52,18 +52,18 @@ function ansible_install { jq fi - sudo -H -E pip install --upgrade pip - sudo -H -E pip install --upgrade setuptools + sudo -H -E pip3 install --upgrade pip + sudo -H -E pip3 install --upgrade setuptools # NOTE(lamt) Preinstalling a capped version of cmd2 to address bug: # https://github.com/python-cmd2/cmd2/issues/421 - sudo -H -E pip install --upgrade "cmd2<=0.8.7" - sudo -H -E pip install --upgrade pyopenssl + sudo -H -E pip3 install --upgrade "cmd2<=0.8.7" + sudo -H -E pip3 install --upgrade pyopenssl # NOTE(srwilkers): Pinning ansible to 2.5.5, as pip installs 2.6 by default. # 2.6 introduces a new command flag (init) for the docker_container module # that is incompatible with what we have currently. 2.5.5 ensures we match # what's deployed in the gates - sudo -H -E pip install --upgrade "ansible==2.5.5" - sudo -H -E pip install --upgrade \ + sudo -H -E pip3 install --upgrade "ansible==2.5.5" + sudo -H -E pip3 install --upgrade \ ara \ yq } diff --git a/tools/images/kubeadm-aio/Dockerfile b/tools/images/kubeadm-aio/Dockerfile index 750abbc4a..282ab0c0b 100644 --- a/tools/images/kubeadm-aio/Dockerfile +++ b/tools/images/kubeadm-aio/Dockerfile @@ -71,16 +71,16 @@ RUN set -ex ;\ ca-certificates \ curl \ jq \ - python-pip \ + python3-pip \ gawk ;\ - pip --no-cache-dir install --upgrade pip==18.1 ;\ + pip3 --no-cache-dir install --upgrade pip==18.1 ;\ hash -r ;\ - pip --no-cache-dir install --upgrade setuptools ;\ + pip3 --no-cache-dir install --upgrade setuptools ;\ # NOTE(srwilkers): Pinning ansible to 2.5.5, as pip installs 2.6 by default. # 2.6 introduces a new command flag (init) for the docker_container module # that is incompatible with what we have currently. 2.5.5 ensures we match # what's deployed in the gates - pip --no-cache-dir install --upgrade \ + pip3 --no-cache-dir install --upgrade \ requests \ kubernetes \ "ansible==2.5.5" ;\