diff --git a/nodemgmt-scripts.sh b/nodemgmt-scripts.sh index 743baf95..bc32dec9 100755 --- a/nodemgmt-scripts.sh +++ b/nodemgmt-scripts.sh @@ -1368,9 +1368,9 @@ SERVICE(){ else PH_CMD="ssh root@${!NT_HOST}" fi - ${PH_CMD} "echo -e \"Service ${1} ${2}\" > /etc/nginx/test.repl" + ${PH_CMD} "echo -e \"Service ${1} ${2}\" > /etc/nginx/test.repl 2>&1" if [ "$NODE_TYPE" != "NC" ]; then - ${PH_CMD} "echo -e \"Service ${1} ${2}\" > /etc/letsencrypt/test.repl" + ${PH_CMD} "echo -e \"Service ${1} ${2}\" > /etc/letsencrypt/test.repl 2>&1" fi for nip in "${!NT_HOSTS}"; do checkhost=$(CHECK_HOST ${nip}) @@ -1378,8 +1378,8 @@ SERVICE(){ if [ "${nip}" != "${!NT_HOST}" ]; then checked=false until [ "${checked}" = "" ]; do - checked="`${PH_CMD} \"ssh root@${nip} 'if [ -f /etc/nginx/test.repl ]; then cat /etc/nginx/test.repl; fi' | diff - /etc/nginx/test.repl\"`" - checked="`${PH_CMD} \"ssh root@${nip} 'if [ -f /etc/nginx/test.repl ]; then cat /etc/letsencrypt/test.repl; fi' | diff - /etc/letsencrypt/test.repl\"`" + checked="`${PH_CMD} \"ssh root@${nip} 'if [ -f /etc/nginx/test.repl ]; then cat /etc/nginx/test.repl; fi' | diff - /etc/nginx/test.repl 2>&1\"`" + checked="`${PH_CMD} \"ssh root@${nip} 'if [ -f /etc/nginx/test.repl ]; then cat /etc/letsencrypt/test.repl; fi' | diff - /etc/letsencrypt/test.repl 2>&1\"`" done fi fi