File tree Expand file tree Collapse file tree 1 file changed +7
-4
lines changed
data/data/bootstrap/baremetal/files/usr/local/bin Expand file tree Collapse file tree 1 file changed +7
-4
lines changed Original file line number Diff line number Diff line change @@ -36,7 +36,7 @@ echo Nodes are all active
3636BAREMETAL_OPERATOR_IMAGE=$( image_for baremetal-operator)
3737
3838for node in $( curl -s " ${ironic_url} /nodes" | jq -r ' .nodes[] | .uuid' ) ; do
39- name=$( curl -H " X-OpenStack-Ironic-API-Version: 1.9" -s " ${ironic_url} /nodes/${node} " | jq -r .name)
39+ name=$( curl -H " X-OpenStack-Ironic-API-Version: 1.9" -s " ${ironic_url} /nodes/${node} " | jq -r .name | cut -d " ~ " -f 2 )
4040 echo " Host $name , UUID: $node "
4141 # And use the baremetal operator tool to load the introspection data into
4242 # the BareMetalHost CRs as annotations, which BMO then picks up.
@@ -49,10 +49,13 @@ for node in $(curl -s "${ironic_url}/nodes" | jq -r '.nodes[] | .uuid'); do
4949 oc annotate --overwrite -n openshift-machine-api baremetalhosts " $name " ' baremetalhost.metal3.io/status' =" $HARDWARE_DETAILS " ' baremetalhost.metal3.io/paused-'
5050done
5151
52- # This delay is needed to ensure that Terraform sees that the hosts are
53- # deployed before we stop ironic. Terraform is polling every 10s.
54- sleep 30
5552# Shut down ironic containers so that the API VIP can fail over to the control
5653# plane.
5754echo " Stopping provisioning services..."
5855systemctl stop ironic.service
56+
57+ echo " Wait for control plane to fail over"
58+ sleep 30
59+
60+ echo " Unpause all baremetal hosts"
61+ oc annotate --overwrite -n openshift-machine-api baremetalhosts --all " baremetalhost.metal3.io/paused-"
You can’t perform that action at this time.
0 commit comments