Wait for overcloud manage and provide state transitions

During the 'kayobe overcloud provision' command, wait for the
nodes to become manageable and available.

Adds two variables, 'wait_manageable_timeout' and
'wait_available_timeout', to control the wait timeout.

Change-Id: I7435bd06d58501e361312bacfa4e55394aba5b57
This commit is contained in:
Mark Goddard 2021-02-04 15:44:40 +00:00
parent b8ef36047c
commit aaf9572d08

View File

@ -6,6 +6,8 @@
tags:
- provision
vars:
wait_manageable_timeout: 60
wait_available_timeout: 60
# Set to False to avoid waiting for the nodes to become active.
wait_active: True
wait_active_timeout: 600
@ -82,7 +84,7 @@
-e @/etc/bifrost/dib.yml
--limit {{ inventory_hostname }}
-m command
-a "baremetal node manage {% raw %}{{ inventory_hostname }}{% endraw %}"'
-a "baremetal node manage --wait {{ wait_manageable_timeout }} {% raw %}{{ inventory_hostname }}{% endraw %}"'
register: manage_result
until: manage_result is successful or 'is locked by host' in manage_result.stdout
retries: "{{ ironic_retries }}"
@ -107,7 +109,7 @@
-e @/etc/bifrost/dib.yml
--limit {{ inventory_hostname }}
-m command
-a "baremetal node provide {% raw %}{{ inventory_hostname }}{% endraw %}"'
-a "baremetal node provide --wait {{ wait_available_timeout }} {% raw %}{{ inventory_hostname }}{% endraw %}"'
register: provide_result
until: provide_result is successful or 'is locked by host' in provide_result.stdout
retries: "{{ ironic_retries }}"