From dfb3c066a1c325ba7ca028be98d9ec04af994f48 Mon Sep 17 00:00:00 2001 From: Cédric Ollivier Date: Tue, 5 Sep 2017 19:11:21 +0200 Subject: Select stable/ocata packages MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit It also protects if flask is already installed. Change-Id: Iec5d65fe307d702ec6f600333d6bc9cc3ab2ee33 Signed-off-by: Cédric Ollivier --- tests/run.sh | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/tests/run.sh b/tests/run.sh index e1875e09..b5c56872 100755 --- a/tests/run.sh +++ b/tests/run.sh @@ -42,6 +42,8 @@ ceilometer="ceilometer $as_doctor_user" as_admin_user="--os-username admin --os-project-name $DOCTOR_PROJECT --os-tenant-name $DOCTOR_PROJECT" +upper_constraints="https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt?h=stable/ocata" +pip_install="pip install -c${upper_constraints}" # Functions @@ -477,16 +479,16 @@ cleanup() { } setup_python_packages() { - sudo pip install flask==0.10.1 - command -v openstack || sudo pip install python-openstackclient==2.3.0 - command -v ceilometer || sudo pip install python-ceilometerclient==2.6.2 - command -v congress || sudo pip install python-congressclient==1.5.0 + pip freeze |grep -i flask\= > /dev/null || sudo ${pip_install} flask + command -v openstack || sudo ${pip_install} python-openstackclient + command -v ceilometer || sudo ${pip_install} python-ceilometerclient + command -v congress || sudo ${pip_install} python-congressclient } # Main process if [[ $PYTHON_ENABLE == [Tt]rue ]]; then - which tox || sudo pip install tox + which tox || sudo ${pip_install} tox if [ -f /usr/bin/apt-get ]; then sudo apt-get install -y python3-dev elif [ -f /usr/bin/yum ] ; then -- cgit 1.2.3-korg