Update nodemgmt-scripts.sh
This commit is contained in:
@@ -174,14 +174,14 @@ STATUS(){
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "${ST_ACTION}" != "dockers" ]; then
|
if [ "${ST_ACTION}" != "dockers" ]; then
|
||||||
srvcs=${NTYPE}_SERVICES_CHECK[@]; srvcs=${!srvcs}
|
srvcs=${NTYPE}_SERVICES_CHECK[@];
|
||||||
srvcstotest="$(join_by " " ${srvcs})"
|
srvcstotest="$(join_by " " ${srvcs})"
|
||||||
|
|
||||||
[ "${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
|
[ "${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
|
if [ ${NOGOCHK} == true ]; then
|
||||||
srvctst=(`${NCMD} systemctl is-active ${srvcstotest}`)
|
srvctst=(`${NCMD} systemctl is-active ${srvcstotest}`)
|
||||||
sr=0
|
sr=0
|
||||||
for srvc in "${srvcs[@]}"; do
|
for srvc in "${!srvcs}"; do
|
||||||
if [ "${ST_ACTION}" != "check" ]; then
|
if [ "${ST_ACTION}" != "check" ]; then
|
||||||
if [ "${ST_ACTION}" != "report" ]; 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
|
c=0; cw=30; spc=''; spc1=${cw}-${#NM_SERVICES[${srvc}]}; until [ $c = ${spc1} ]; do spc="${spc} "; c=`expr $c + 1`; done
|
||||||
|
|||||||
Reference in New Issue
Block a user