From 5c341a7bada78edab5f3d132d55adb00eaf2413f Mon Sep 17 00:00:00 2001 From: Jesse Pretorius Date: Tue, 29 May 2018 12:42:30 +0100 Subject: [PATCH] Use upper constraints when installing ARA Currently the installation of ARA does not apply the same pip options (including constraints, proxy settings, etc) as the ansible bootstrap. This may result in unexpected side-effects. To ensure that we're keeping things consistent, we apply the same pip options as those used for the Ansible bootstrap. Backport note: We include the os_rally role requirement to ensure that the repo build is able to complete. Depends-On: https://review.openstack.org/570929 Change-Id: I5f20a130032e1b65dc78828344345515975da4dc (cherry picked from commit f4e8e7f82a94379bc50779e9027876bce23d3a90) --- ansible-role-requirements.yml | 2 +- releasenotes/notes/cmd2-0.9.0-838765e91d9be69e.yaml | 7 +++++++ scripts/gate-check-commit.sh | 8 ++++++-- 3 files changed, 14 insertions(+), 3 deletions(-) create mode 100644 releasenotes/notes/cmd2-0.9.0-838765e91d9be69e.yaml diff --git a/ansible-role-requirements.yml b/ansible-role-requirements.yml index b538d98f8c..be297fc989 100644 --- a/ansible-role-requirements.yml +++ b/ansible-role-requirements.yml @@ -117,7 +117,7 @@ - name: os_rally scm: git src: https://git.openstack.org/openstack/openstack-ansible-os_rally - version: 0289542a29f4705a6e16c69d19a2d1718d85cf22 + version: 37f48c1e029b82dabd86e72ce4497e41d186a679 - name: os_sahara scm: git src: https://git.openstack.org/openstack/openstack-ansible-os_sahara diff --git a/releasenotes/notes/cmd2-0.9.0-838765e91d9be69e.yaml b/releasenotes/notes/cmd2-0.9.0-838765e91d9be69e.yaml new file mode 100644 index 0000000000..70dc3d9d1d --- /dev/null +++ b/releasenotes/notes/cmd2-0.9.0-838765e91d9be69e.yaml @@ -0,0 +1,7 @@ +--- +issues: + - | + All OSA releases earlier than 17.0.5, 16.0.4, and 15.1.22 will fail to build the + rally venv due to the release of the new cmd2-0.9.0 python library. Deployers are + encouraged to update to the latest OSA release which pins to an appropriate version + which is compatible with python2. diff --git a/scripts/gate-check-commit.sh b/scripts/gate-check-commit.sh index c0cf397925..c6b25065c2 100755 --- a/scripts/gate-check-commit.sh +++ b/scripts/gate-check-commit.sh @@ -111,10 +111,14 @@ source "${OSA_CLONE_DIR}/scripts/bootstrap-ansible.sh" ARA_SRC_HOME="${HOME}/src/git.openstack.org/openstack/ara" if [[ -d "${ARA_SRC_HOME}" ]]; then # This installs from a git checkout - /opt/ansible-runtime/bin/pip install ${ARA_SRC_HOME} "${ANSIBLE_PACKAGE:-ansible}" + # PIP_COMMAND and PIP_OPTS are exported by the bootstrap-ansible script. + # PIP_OPTS contains the whole set of constraints that need to be applied. + ${PIP_COMMAND} install ${PIP_OPTS} ${ARA_SRC_HOME} "${ANSIBLE_PACKAGE:-ansible}" else # This installs from pypi - /opt/ansible-runtime/bin/pip install ara==0.14.0 "${ANSIBLE_PACKAGE:-ansible}" + # PIP_COMMAND and PIP_OPTS are exported by the bootstrap-ansible script. + # PIP_OPTS contains the whole set of constraints that need to be applied. + ${PIP_COMMAND} install ${PIP_OPTS} ara==0.14.0 "${ANSIBLE_PACKAGE:-ansible}" fi # Dynamically retrieve the location of the ARA callback so we are able to find # it on both py2 and py3