diff options
Diffstat (limited to 'utils/fetch_os_creds.sh')
-rwxr-xr-x | utils/fetch_os_creds.sh | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/utils/fetch_os_creds.sh b/utils/fetch_os_creds.sh index 312e1ac5c..8fbbdce65 100755 --- a/utils/fetch_os_creds.sh +++ b/utils/fetch_os_creds.sh @@ -144,6 +144,13 @@ if [ "$installer_type" == "fuel" ]; then echo $auth_url >> $dest_path elif [ "$installer_type" == "apex" ]; then + if ! ipcalc -c $installer_ip; then + installer_ip=$(virsh domifaddr undercloud | grep -Eo '[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}') + if [ -z "$installer_ip" ] || ! $(ipcalc -c $installer_ip); then + echo "Unable to find valid IP for Apex undercloud: ${installer_ip}" + exit 1 + fi + fi verify_connectivity $installer_ip # The credentials file is located in the Instack VM (192.0.2.1) |