Update test.sh

This commit is contained in:
2019-07-25 20:32:14 -05:00
parent a25d2d40df
commit af1739e5a4

18
test.sh
View File

@@ -25,21 +25,7 @@ fi
echo -en "${idsCL[LightYellow]}Waiting for nginx config replication across the nodes... ${idsCL[Default]}"
CHECK_HOST 10.5.10.53
PH_CMD="ssh root@${WEB_HOSTS[0]}"
echo "HERE: ${PH_CMD}"
${PH_CMD} rm -f /etc/nginx/test.repl
${PH_CMD} "echo -e \"Service ${1} ${2}\" > /etc/nginx/test.repl"
for nip in "${WEB_HOSTS[@]}"; do
if [ "${nip}" != "${WEB_HOSTS[0]}" ]; then
checked=false
until [ "${checked}" = "" ]; do
checked="`${PH_CMD} \"ssh root@${nip} \"cat /etc/nginx/test.repl\" | diff - /etc/nginx/test.repl\"`"
done
fi
done
echo -e "${idsCL[Green]}Completed${idsCL[Default]}"