Merge "Choose version of Ansible OpenStack collection based on RDO release"
This commit is contained in:
commit
b5340dc71b
|
@ -10,6 +10,10 @@ collections:
|
||||||
# and otherwise will fail with "Non integer values in LooseVersion" [2].
|
# and otherwise will fail with "Non integer values in LooseVersion" [2].
|
||||||
# [1] https://semver.org/
|
# [1] https://semver.org/
|
||||||
# [2] https://bugzilla.redhat.com/show_bug.cgi?id=2109807
|
# [2] https://bugzilla.redhat.com/show_bug.cgi?id=2109807
|
||||||
|
#
|
||||||
|
# FIXME(jmeng): Collection openstack.cloud aka git+https://opendev.org/openstack/
|
||||||
|
# ansible-collections-openstack is installed with quickstart.sh because the
|
||||||
|
# version to be installed depends on the RDO release.
|
||||||
- name: ansible.utils
|
- name: ansible.utils
|
||||||
source: https://galaxy.ansible.com
|
source: https://galaxy.ansible.com
|
||||||
version: 2.4.2
|
version: 2.4.2
|
||||||
|
@ -34,10 +38,6 @@ collections:
|
||||||
- name: openstack.config_template
|
- name: openstack.config_template
|
||||||
source: git+https://opendev.org/openstack/ansible-config_template.git
|
source: git+https://opendev.org/openstack/ansible-config_template.git
|
||||||
type: git
|
type: git
|
||||||
- name: openstack.cloud
|
|
||||||
source: git+https://opendev.org/openstack/ansible-collections-openstack
|
|
||||||
type: git
|
|
||||||
version: 1.8.0
|
|
||||||
- name: tripleo.operator
|
- name: tripleo.operator
|
||||||
source: git+https://opendev.org/openstack/tripleo-operator-ansible/
|
source: git+https://opendev.org/openstack/tripleo-operator-ansible/
|
||||||
type: git
|
type: git
|
||||||
|
|
|
@ -159,7 +159,9 @@ repos:
|
||||||
|
|
||||||
- type: file
|
- type: file
|
||||||
filename: delorean-master-deps.repo
|
filename: delorean-master-deps.repo
|
||||||
down_url: "${NODEPOOL_RDO_PROXY}/{{ distro_ver }}-{{ release }}/delorean-deps.repo"
|
# FIXME(jmeng): Remove aoc-temp repository once prerelease of ansible-collections-openstack 2.0.0 has been promoted
|
||||||
|
#down_url: "${NODEPOOL_RDO_PROXY}/{{ distro_ver }}-{{ release }}/delorean-deps.repo"
|
||||||
|
down_url: "${NODEPOOL_RDO_PROXY}/{{ distro_ver }}-{{ release }}/aoc-temp/delorean-deps.repo"
|
||||||
|
|
||||||
# CentOS related repos
|
# CentOS related repos
|
||||||
- type: generic
|
- type: generic
|
||||||
|
|
|
@ -129,7 +129,9 @@ repos:
|
||||||
|
|
||||||
- type: file
|
- type: file
|
||||||
filename: delorean-master-deps.repo
|
filename: delorean-master-deps.repo
|
||||||
down_url: "${NODEPOOL_RDO_PROXY}/{{ distro_ver }}-{{ release }}/delorean-deps.repo"
|
# FIXME(jmeng): Remove aoc-temp repository once prerelease of ansible-collections-openstack 2.0.0 has been promoted
|
||||||
|
#down_url: "${NODEPOOL_RDO_PROXY}/{{ distro_ver }}-{{ release }}/delorean-deps.repo"
|
||||||
|
down_url: "${NODEPOOL_RDO_PROXY}/{{ distro_ver }}-{{ release }}/aoc-temp/delorean-deps.repo"
|
||||||
|
|
||||||
# CentOS related repos
|
# CentOS related repos
|
||||||
- type: generic
|
- type: generic
|
||||||
|
|
|
@ -128,7 +128,9 @@ repos:
|
||||||
|
|
||||||
- type: file
|
- type: file
|
||||||
filename: delorean-zed-deps.repo
|
filename: delorean-zed-deps.repo
|
||||||
down_url: "${NODEPOOL_RDO_PROXY}/{{ distro_ver }}-{{ release }}/delorean-deps.repo"
|
# FIXME(jmeng): Remove aoc-temp repository once prerelease of ansible-collections-openstack 2.0.0 has been promoted
|
||||||
|
#down_url: "${NODEPOOL_RDO_PROXY}/{{ distro_ver }}-{{ release }}/delorean-deps.repo"
|
||||||
|
down_url: "${NODEPOOL_RDO_PROXY}/{{ distro_ver }}-{{ release }}/aoc-temp/delorean-deps.repo"
|
||||||
|
|
||||||
# CentOS related repos
|
# CentOS related repos
|
||||||
- type: generic
|
- type: generic
|
||||||
|
|
|
@ -158,7 +158,9 @@ repos:
|
||||||
|
|
||||||
- type: file
|
- type: file
|
||||||
filename: delorean-zed-deps.repo
|
filename: delorean-zed-deps.repo
|
||||||
down_url: "${NODEPOOL_RDO_PROXY}/{{ distro_ver }}-{{ release }}/delorean-deps.repo"
|
# FIXME(jmeng): Remove aoc-temp repository once prerelease of ansible-collections-openstack 2.0.0 has been promoted
|
||||||
|
#down_url: "${NODEPOOL_RDO_PROXY}/{{ distro_ver }}-{{ release }}/delorean-deps.repo"
|
||||||
|
down_url: "${NODEPOOL_RDO_PROXY}/{{ distro_ver }}-{{ release }}/aoc-temp/delorean-deps.repo"
|
||||||
|
|
||||||
# CentOS related repos
|
# CentOS related repos
|
||||||
- type: generic
|
- type: generic
|
||||||
|
|
|
@ -133,6 +133,30 @@ install_ansible_collections_deps(){
|
||||||
-r ansible-collection-requirements.yml \
|
-r ansible-collection-requirements.yml \
|
||||||
-p $VIRTUAL_ENV/share/ansible/collections
|
-p $VIRTUAL_ENV/share/ansible/collections
|
||||||
|
|
||||||
|
# Install openstack.cloud release depending on the RDO release if is not installed
|
||||||
|
#
|
||||||
|
# Some jobs run quickstart.sh several times, so ansible-galaxy might get called twice or more.
|
||||||
|
# On such subsequent runs, ansible-galaxy will find the collections to be installed already and
|
||||||
|
# will use the optional version part of the SCM pointer to compare it against existing
|
||||||
|
# collections. This comparison will fail with "Non integer values in LooseVersion" [2] if the
|
||||||
|
# version in the SCM pointer is not a valid semantic version [1].
|
||||||
|
# Both a branch name and a commit hash are not valid semantic versions and thus we can only run
|
||||||
|
# ansible-galaxy on the first run aka if openstack.cloud has not been installed yet.
|
||||||
|
# [1] https://semver.org/
|
||||||
|
# [2] https://bugzilla.redhat.com/show_bug.cgi?id=2109807
|
||||||
|
if [[ ! -d $VIRTUAL_ENV/share/ansible/collections/ansible_collections/openstack/cloud ]]; then
|
||||||
|
if [[ $QUICKSTART_RELEASE =~ .*(train|victoria|wallaby).* ]]; then
|
||||||
|
retry 10 ansible-galaxy collection install -vvv --force \
|
||||||
|
git+https://opendev.org/openstack/ansible-collections-openstack,stable/1.0.0 \
|
||||||
|
-p $VIRTUAL_ENV/share/ansible/collections
|
||||||
|
else
|
||||||
|
# FIXME(jmeng): Replace commit hash with 'master' once Ansible OpenStack collection 2.0.0 has been released
|
||||||
|
retry 10 ansible-galaxy collection install -vvv --force \
|
||||||
|
git+https://opendev.org/openstack/ansible-collections-openstack,ed36d82a0c60a841d2f30c61a50d60531481b2cc \
|
||||||
|
-p $VIRTUAL_ENV/share/ansible/collections
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
# Use collections already cloned by CI if they're available
|
# Use collections already cloned by CI if they're available
|
||||||
OS_COLLECTIONS="ansible-config_template ansible-collections-openstack \
|
OS_COLLECTIONS="ansible-config_template ansible-collections-openstack \
|
||||||
tripleo-operator-ansible"
|
tripleo-operator-ansible"
|
||||||
|
|
Loading…
Reference in New Issue