diff --git a/deployment/nova/nova-compute-container-puppet.yaml b/deployment/nova/nova-compute-container-puppet.yaml index ca432ce2d9..27964abee2 100644 --- a/deployment/nova/nova-compute-container-puppet.yaml +++ b/deployment/nova/nova-compute-container-puppet.yaml @@ -1109,31 +1109,32 @@ outputs: -> {{ nova_compute_service }}. when: - (nova_compute_service | length) > 1 - - name: Disable nova-compute service - command: openstack compute service set {{ nova_compute_service[0].Host }} nova-compute --disable - delegate_to: localhost - check_mode: no + - name: Disable nova services when: - - (nova_compute_service | length) <= 1 - - not is_additional_cell|bool - - name: Stop nova-compute healthcheck container - service: - name: tripleo_nova_compute_healthcheck - state: stopped - enabled: no - become: true - - name: Stop nova-compute container - service: - name: tripleo_nova_compute - state: stopped - enabled: no - become: true - - name: Delete nova-compute service - command: openstack compute service delete {{ nova_compute_service[0].ID }} - delegate_to: localhost - check_mode: no - when: - - (nova_compute_service | length) <= 1 + - (nova_compute_service | length) == 1 + block: + - name: Disable nova-compute service + command: openstack compute service set {{ nova_compute_service[0].Host }} nova-compute --disable + delegate_to: localhost + check_mode: no + when: + - not is_additional_cell|bool + - name: Stop nova-compute healthcheck container + service: + name: tripleo_nova_compute_healthcheck + state: stopped + enabled: no + become: true + - name: Stop nova-compute container + service: + name: tripleo_nova_compute + state: stopped + enabled: no + become: true + - name: Delete nova-compute service + command: openstack compute service delete {{ nova_compute_service[0].ID }} + delegate_to: localhost + check_mode: no fast_forward_upgrade_tasks: - when: - step|int == 0