From a6f6a00de72ef7cb1d5dc159cb94e44f268dbea4 Mon Sep 17 00:00:00 2001 From: David Schroeder Date: Thu, 27 Apr 2023 09:54:02 -0500 Subject: [PATCH] Update nodemgmt-scripts.sh --- nodemgmt-scripts.sh | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/nodemgmt-scripts.sh b/nodemgmt-scripts.sh index 8812d509..a4c0304c 100755 --- a/nodemgmt-scripts.sh +++ b/nodemgmt-scripts.sh @@ -176,14 +176,12 @@ STATUS(){ if [ "${ST_ACTION}" != "dockers" ]; then srvcs=${NTYPE}_SERVICES_CHECK[@]; srvcs=${!srvcs} srvcstotest="$(join_by " " ${srvcs})" - echo "H: $srvcstotest" [ "${srvc}" == "gitea" ] && [ "${NTYPE}" == "WEB" ] && [[ $($NCMD /sbin/ip -o -4 addr list eth0 | awk '{print $4}' | cut -d/ -f1) != *${WEB_HOSTS[0]}* ]] && NOGOCHK=false || NOGOCHK=true if [ ${NOGOCHK} == true ]; then srvctst=(`${NCMD} systemctl is-active ${srvcstotest}`) - echo "H: `${NCMD} systemctl is-active ${srvcstotest}`" sr=0 - for srvc in "${srvcs}"; do + for srvc in "${srvcs[@]}"; do if [ "${ST_ACTION}" != "check" ]; then if [ "${ST_ACTION}" != "report" ]; then c=0; cw=30; spc=''; spc1=${cw}-${#NM_SERVICES[${srvc}]}; until [ $c = ${spc1} ]; do spc="${spc} "; c=`expr $c + 1`; done @@ -200,9 +198,6 @@ STATUS(){ mysqlgo=true fi # echo "mysqlgo=${mysqlgo}" - - echo "H: '${srvctst[$sr]}' - '$nip' - '$srvc' - '${mysqlgo}'" - if [ "${srvctst[$sr]}" != "active" ] && [ "${mysqlgo}" != "true" ]; then if [ ! -f ${FOLDER}/${nip}-${srvc}.down ]; then [ "${ST_ACTION}" != "check" ] && echo -e "${idsCL[Red]}Not Running${idsCL[Default]}"