Merge "CI: Use upper constraints when installing clients"

This commit is contained in:
Zuul 2020-02-25 15:07:44 +00:00 committed by Gerrit Code Review
commit dfe2f9d0c7
3 changed files with 13 additions and 11 deletions

View File

@ -269,6 +269,7 @@
TAG: "{{ build_image_tag }}"
KOLLA_SRC_DIR: "{{ ansible_env.HOME }}/src/opendev.org/openstack/kolla"
SCENARIO: "{{ scenario }}"
UPPER_CONSTRAINTS: "{{ ansible_env.HOME }}/src/opendev.org/openstack/requirements/upper-constraints.txt"
- name: Run init-swift.sh script
script:

View File

@ -10,22 +10,22 @@ GIT_PROJECT_DIR=$(mktemp -d)
function setup_openstack_clients {
# Prepare virtualenv for openstack deployment tests
local packages=(python-openstackclient python-heatclient)
if [[ $SCENARIO == zun ]]; then
packages+=(python-zunclient)
fi
if [[ $SCENARIO == ironic ]]; then
packages+=(python-ironicclient)
fi
if [[ $SCENARIO == masakari ]]; then
packages+=(python-masakariclient)
fi
if [[ "debian" == $BASE_DISTRO ]]; then
sudo apt -y install python3-venv
fi
python3 -m venv ~/openstackclient-venv
~/openstackclient-venv/bin/pip install -U pip
~/openstackclient-venv/bin/pip install python-openstackclient
~/openstackclient-venv/bin/pip install python-heatclient
if [[ $SCENARIO == zun ]]; then
~/openstackclient-venv/bin/pip install python-zunclient
fi
if [[ $SCENARIO == ironic ]]; then
~/openstackclient-venv/bin/pip install python-ironicclient
fi
if [[ $SCENARIO == masakari ]]; then
~/openstackclient-venv/bin/pip install python-masakariclient
fi
~/openstackclient-venv/bin/pip install -c $UPPER_CONSTRAINTS ${packages[@]}
}
function setup_config {

View File

@ -8,6 +8,7 @@
timeout: 7200
required-projects:
- openstack/kolla-ansible
- openstack/requirements
irrelevant-files:
- ^.*\.rst$
- ^doc/.*