Update nodemgmt-scripts.sh
This commit is contained in:
@@ -1197,11 +1197,15 @@ SERVICE(){
|
|||||||
if [ "${3}" != "q" ]; then
|
if [ "${3}" != "q" ]; then
|
||||||
echo -en "${idsCL[LightYellow]}Verifying nginx config and ssl cert replication across the nodes... ${idsCL[Default]}"
|
echo -en "${idsCL[LightYellow]}Verifying nginx config and ssl cert replication across the nodes... ${idsCL[Default]}"
|
||||||
fi
|
fi
|
||||||
PH_CMD="ssh root@${!NT_HOST}"
|
if [[ $(/sbin/ip -o -4 addr list eth0 | awk '{print $4}' | cut -d/ -f1) == *"${nip}"* ]]; then
|
||||||
|
PH_CMD=""
|
||||||
|
else
|
||||||
|
PH_CMD="ssh root@${!NT_HOST}"
|
||||||
|
fi
|
||||||
|
echo "H: $PH_CMD"
|
||||||
${PH_CMD} "echo -e \"Service ${1} ${2}\" > /etc/nginx/test.repl"
|
${PH_CMD} "echo -e \"Service ${1} ${2}\" > /etc/nginx/test.repl"
|
||||||
${PH_CMD} "echo -e \"Service ${1} ${2}\" > /etc/letsencrypt/test.repl"
|
${PH_CMD} "echo -e \"Service ${1} ${2}\" > /etc/letsencrypt/test.repl"
|
||||||
for nip in "${!NT_HOSTS}"; do
|
for nip in "${!NT_HOSTS}"; do
|
||||||
echo "1: $nip"
|
|
||||||
checkhost=$(CHECK_HOST ${nip})
|
checkhost=$(CHECK_HOST ${nip})
|
||||||
if [ "${checkhost}" != "false" ]; then
|
if [ "${checkhost}" != "false" ]; then
|
||||||
if [ "${nip}" != "${!NT_HOST}" ]; then
|
if [ "${nip}" != "${!NT_HOST}" ]; then
|
||||||
|
|||||||
Reference in New Issue
Block a user