Merge "CentOS Stream: Use a variable for openstack_tag_suffix" into stable/train

This commit is contained in:
Zuul 2022-03-29 15:24:43 +00:00 committed by Gerrit Code Review
commit e51134e009
5 changed files with 30 additions and 2 deletions

View File

@ -512,7 +512,7 @@ openstack_release: "train"
# Docker image tag used by default.
openstack_tag: "{{ openstack_release ~ openstack_tag_suffix }}"
# TODO(mgoddard): Set to an empty string when CentOS 7 is no longer supported.
openstack_tag_suffix: "{{ '' if kolla_base_distro != 'centos' or ansible_distribution_major_version == '7' else '-centos8' }}"
openstack_tag_suffix: "{{ '' if kolla_base_distro != 'centos' or ansible_distribution_major_version == '7' else '-centos8s' if 'Stream' in (kolla_centos_release['content'] | default() | b64decode ) else '-centos8' }}"
openstack_logging_debug: "False"
openstack_region_name: "RegionOne"

View File

@ -12,6 +12,10 @@
group_by:
key: "openstack_release_{{ openstack_release }}"
- name: Group hosts based on OS distribution
group_by:
key: "kolla_distribution_{{ ansible_facts['distribution'] }}"
- name: Group hosts based on Kolla action
group_by:
key: "kolla_action_{{ kolla_action }}"
@ -92,6 +96,16 @@
- enable_zun_{{ enable_zun | bool }}
tags: always
- name: Check CentOS variant
gather_facts: false
# Apply only on CentOS hosts
hosts: kolla_distribution_CentOS
tasks:
- name: Slurp /etc/centos-release
slurp:
src: /etc/centos-release
register: kolla_centos_release
- name: Apply role prechecks
gather_facts: false
# Apply only when kolla action is 'precheck'.

View File

@ -401,6 +401,16 @@ There are a few options that are required to deploy Kolla-Ansible:
kolla_base_distro: "centos"
You can also use CentOS Stream 8 - it's recommended for new installations
because CentOS Linux 8 was supported only until `31st Dec 2021 <https://wiki.centos.org/About/Product>`__.
By default Kolla-Ansible will use ``-centos8s`` ``openstack_tag_suffix`` on CentOS Stream 8 hosts,
to override that behaviour please set ``openstack_tag_suffix`` to an empty/different value.
.. code-block:: yaml
openstack_tag_suffix: ""
Next "type" of installation needs to be configured.
Choices are:

View File

@ -24,7 +24,7 @@
#openstack_tag: "{{ openstack_release ~ openstack_tag_suffix }}"
# Suffix applied to openstack_release to generate openstack_tag.
#openstack_tag_suffix: "{{ '' if base_distro != 'centos' or ansible_distribution_major_version == '7' else '-centos8' }}"
#openstack_tag_suffix: "{{ '' if kolla_base_distro != 'centos' or ansible_distribution_major_version == '7' else '-centos8s' if 'Stream' in (kolla_centos_release['content'] | default() | b64decode ) else 'centos8s' }}"
# Location of configuration overrides
#node_custom_config: "/etc/kolla/config"

View File

@ -23,6 +23,10 @@ docker_custom_config:
- {{ infra_dockerhub_mirror }}
{% endif %}
{% if kolla_python_version is defined and not is_previous_release %}
distro_python_version: "{{ kolla_python_version }}"
{% endif %}
# Use a random router id, otherwise it may result in the same router id
# in the CI gate.
keepalived_virtual_router_id: "{{ 250 | random(1) }}"