File tree 1 file changed +9
-0
lines changed
ci-operator/step-registry/ipi/conf/nutanix/context
1 file changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -45,8 +45,16 @@ clusters_json=$(curl -ks -u "${un}":"${pw}" -X POST ${api_ep} -H "Content-Type:
45
45
# For QE nutanix with multi zone, we need to select PE by host IP
46
46
if [[ $LEASED_RESOURCE =~ " nutanix-qe" ]]; then
47
47
pe_uuid=$( echo " ${clusters_json} " | jq " .entities[] | select (.spec.resources.network.external_ip == \" ${prism_element_host} \" ) | .metadata.uuid" | head -n 1)
48
+ pe_name=$( echo " ${clusters_json} " | jq " .entities[] | select (.spec.resources.network.external_ip == \" ${prism_element_host} \" ) | .spec.name" | head -n 1)
48
49
else
49
50
pe_uuid=$( echo " ${clusters_json} " | jq ' .entities[] | select (.spec.name != "Unnamed") | .metadata.uuid' | head -n 1)
51
+ pe_name=$( echo " ${clusters_json} " | jq -r ' .entities[] | select (.spec.name != "Unnamed") | .spec.name' | head -n 1)
52
+ fi
53
+
54
+
55
+ if [[ -z " ${pe_name} " ]]; then
56
+ echo " $( date -u --rfc-3339=seconds) - Cannot get PE Name"
57
+ exit 1
50
58
fi
51
59
52
60
if [[ -z " ${pe_uuid} " ]]; then
@@ -116,6 +124,7 @@ export PE_PORT='${prism_element_port}'
116
124
export PE_USERNAME='${prism_element_username} '
117
125
export PE_PASSWORD='${prism_element_password} '
118
126
export PE_UUID='${pe_uuid} '
127
+ export PE_NAME='${pe_name} '
119
128
export PE_STORAGE_CONTAINER='${prism_element_storage_container} '
120
129
export SUBNET_UUID='${subnet_uuid} '
121
130
export API_VIP='${API_VIP} '
You can’t perform that action at this time.
0 commit comments