Commit 6e30bc27 authored by Andrea Sciaba's avatar Andrea Sciaba
Browse files

Merge branch 'ekizinev-qa-patch-97296' into 'qa'

Correctly parse output of host command

See merge request !8
parents 9cecebde c2c2a678
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
shopt -s expand_aliases shopt -s expand_aliases
SCRIPT_REVISION="2019-03-05, Dave Dykstra and Edita Kizinevic" SCRIPT_REVISION="2019-04-15, Dave Dykstra and Edita Kizinevic"
# Source the CMS environment # Source the CMS environment
if [ -n "$OSG_GRID" ] ; then if [ -n "$OSG_GRID" ] ; then
...@@ -99,8 +99,8 @@ check_proxies() { ...@@ -99,8 +99,8 @@ check_proxies() {
*"(proxyurl="*) *"(proxyurl="*)
hostname=${proxy#*//} hostname=${proxy#*//}
hostname=${hostname%:*} hostname=${hostname%:*}
IP_addresses=`host $hostname | awk '{ print $NF }'` IP_addresses=`host $hostname | grep "has.*address" | awk '{ print $NF }'`
if [ "$IP_addresses" == "3(NXDOMAIN)" ]; then if [ -z "$IP_addresses" ]; then
echo "Host $hostname not found" echo "Host $hostname not found"
echo echo
ever_failed=true ever_failed=true
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment