From 1db06b32777d677011d36e4744b3f4c7422fd849 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rados=C5=82aw=20Piliszek?= Date: Sat, 5 Mar 2022 16:17:13 +0100 Subject: [PATCH] Ironic: rebootstrap ironic-pxe on upgrade Like other containers. This ensures that upgrade already updates PXE components and no additional deploy/reconfigure is needed. Closes-Bug: #1963752 Change-Id: I368780143086bc5baab1556a5ec75c19950d5e3c --- ansible/roles/ironic/tasks/bootstrap.yml | 19 ------------------- .../roles/ironic/tasks/bootstrap_service.yml | 19 +++++++++++++++++++ .../notes/bug-1963752-ee12e15c17c24bb0.yaml | 6 ++++++ 3 files changed, 25 insertions(+), 19 deletions(-) create mode 100644 releasenotes/notes/bug-1963752-ee12e15c17c24bb0.yaml diff --git a/ansible/roles/ironic/tasks/bootstrap.yml b/ansible/roles/ironic/tasks/bootstrap.yml index ff3bf0e17e..e021492922 100644 --- a/ansible/roles/ironic/tasks/bootstrap.yml +++ b/ansible/roles/ironic/tasks/bootstrap.yml @@ -52,22 +52,3 @@ - inventory_hostname in groups[item.group] - import_tasks: bootstrap_service.yml - -- name: Running Ironic-PXE bootstrap container - vars: - ironic_pxe: "{{ ironic_services['ironic-pxe'] }}" - become: true - kolla_docker: - action: "start_container" - common_options: "{{ docker_common_options }}" - detach: False - environment: - KOLLA_BOOTSTRAP: - KOLLA_CONFIG_STRATEGY: "{{ config_strategy }}" - image: "{{ ironic_pxe.image }}" - labels: - BOOTSTRAP: - name: "bootstrap_ironic_pxe" - restart_policy: no - volumes: "{{ ironic_pxe.volumes }}" - when: inventory_hostname in groups[ironic_pxe.group] diff --git a/ansible/roles/ironic/tasks/bootstrap_service.yml b/ansible/roles/ironic/tasks/bootstrap_service.yml index 35739a714c..e587d3eb50 100644 --- a/ansible/roles/ironic/tasks/bootstrap_service.yml +++ b/ansible/roles/ironic/tasks/bootstrap_service.yml @@ -44,3 +44,22 @@ run_once: True delegate_to: "{{ groups[ironic_inspector.group][0] }}" when: inventory_hostname in groups[ironic_inspector.group] + +- name: Running Ironic-PXE bootstrap container + vars: + ironic_pxe: "{{ ironic_services['ironic-pxe'] }}" + become: true + kolla_docker: + action: "start_container" + common_options: "{{ docker_common_options }}" + detach: False + environment: + KOLLA_BOOTSTRAP: + KOLLA_CONFIG_STRATEGY: "{{ config_strategy }}" + image: "{{ ironic_pxe.image }}" + labels: + BOOTSTRAP: + name: "bootstrap_ironic_pxe" + restart_policy: no + volumes: "{{ ironic_pxe.volumes }}" + when: inventory_hostname in groups[ironic_pxe.group] diff --git a/releasenotes/notes/bug-1963752-ee12e15c17c24bb0.yaml b/releasenotes/notes/bug-1963752-ee12e15c17c24bb0.yaml new file mode 100644 index 0000000000..bf9d2d192e --- /dev/null +++ b/releasenotes/notes/bug-1963752-ee12e15c17c24bb0.yaml @@ -0,0 +1,6 @@ +--- +fixes: + - | + Fixes an issue with Ironic's PXE components not getting updated on + upgrade. + `LP#1963752 `__