Update containers for update jobs

WIP. Just checking what we're missing here.

Resolves: #2015993
Depends-On: https://review.opendev.org/c/openstack/tripleo-ci/+/880162
Depends-On: https://review.opendev.org/c/openstack/tripleo-quickstart/+/883307

Change-Id: I2829307d1013e96317338eccc7a4b16376fb1d2b
This commit is contained in:
Sofer Athlan-Guyot 2023-02-08 16:38:39 +01:00 committed by mciecier
parent a21d6b35ab
commit d358a480d3
3 changed files with 48 additions and 2 deletions

View File

@ -1,4 +1,46 @@
---
# the yum repos ALWAYS need to change
- name: Configure next release repository in the undercloud
hosts: undercloud
tags:
- overcloud-update
vars:
repo_setup_run_update: false
# This should not be enabled because the updating of the packages occurs
# durring the upgrade process. For general installation it's ok to have
# this enabled, but this needs to be disabled for upgrades
ib_gating_repo_update: false
roles:
- role: repo-setup
# note: in upstream CI the gerrit change is built on the content-provider
# this task will be skipped upstream
- name: Build the gerrit changes on the relevant release for the upgrade
hosts: undercloud
tags:
- build
vars:
repo_setup_run_update: false
artg_compressed_gating_repo: "${HOME}/gating_repo.tar.gz"
# This should not be enabled because the updating of the packages occurs
# durring the upgrade process. For general installation it's ok to have
# this enabled, but this needs to be disabled for upgrades
ib_gating_repo_update: false
roles:
- role: build-test-packages
- {role: install-built-repo, when: compressed_gating_repo is defined}
- name: Set container updated dlrn tag for update testing
hosts: undercloud
gather_facts: false
tags:
- overcloud-update
roles:
- role: container-update
when:
- containerized_undercloud|default(false)|bool
- overcloud_update|default(false)|bool
- name: Run tripleo-upgrade role to update the overcloud
hosts: undercloud
gather_facts: true

View File

@ -36,6 +36,9 @@ overcloud_container_cli: podman
local_docker_registry_host: "{{ undercloud_network_gateway|default(undercloud_network_cidr|nthhost(1)) }}"
docker_registry_host: >-
{% if job.consumer_job | default(false) | bool -%}
{% if run_minor_update|default(false)|bool -%}
{{ job.registry_ip_address_branch['wallaby-current'] }}:{{ local_registry_port }}
{%- else -%}
{% if registry_distro is defined and
registry_distro | default('') | length > 0 -%}
{{ job.registry_ip_address_distro[registry_distro] }}:{{ local_registry_port }}
@ -45,8 +48,9 @@ docker_registry_host: >-
{%- else -%}
docker.io
{%- endif -%}
{%- endif -%}
docker_registry_namespace: "tripleo{{ release }}"
docker_image_tag: current-tripleo
# set default and convert job.build_container_images to native
build_container_images: "{{ job.build_container_images|default(false)|bool }}"

View File

@ -4,7 +4,7 @@
- name: set the service environments for container image prepare
set_fact:
prepare_service_env_args: >-
-e {{ overcloud_templates_path }}/environments/docker.yaml
-e {{ overcloud_templates_path }}/environments/podman.yaml
-e {{ overcloud_templates_path }}/ci/environments/{{ composable_scenario }}
when: not composable_scenario|trim == ''