Update status.inc

This commit is contained in:
2023-11-25 21:57:44 -06:00
parent 0fffeab7b2
commit 3ae553753d

View File

@@ -58,7 +58,7 @@ STATUS(){
lip=${RUN_NODE_IP}
echo -e "\n$(DIVIDER)\n${idsCL[Yellow]}${idsST[Bold]} LOCALHOST Service Status${idsST[Reset]}${idsCL[Default]}"
echo -e "$(DIVIDER)\n"
echo -en " ${idsST[Bold]}${idsCL[LightCyan]}${NODE_HOSTNAME} (${lip})${idsST[Reset]}"
echo -en " ${idsST[Bold]}${idsCL[Green]}${NODE_HOSTNAME} (${lip})${idsST[Reset]}"
if ([ "${ST_ACTION}" == "report" ] && [ "${2}" == "email" ]) || [ "${ST_ACTION}" != "report" ]; then
uptime=`uptime -p`
echo -e "${idsCL[LightCyan]} - ${uptime} ${idsCL[LightYellow]}- localhost${idsCL[Default]}"
@@ -82,7 +82,7 @@ STATUS(){
else
spc=' '
fi
echo -en " ${NM_SERVICE_DESC[${srvc}]}${spc}: "
echo -en "${idsCL[White]} ${NM_SERVICE_DESC[${srvc}]}${spc}${idsCL[Default]}: "
fi
if [ "$(systemctl is-active ${srvc})" != "active" ]; then
@@ -205,6 +205,9 @@ STATUS(){
fi
if [ "${ST_ACTION}" != "dockers" ]; then
echo -e "${idsCL[Green]} System Service(s) Status${idsCL[Default]}"
DIVIDER . green 52
srvcs=${NTYPE}_SERVICES_CHECK[@];
srvcstotest="$(join_by " " ${!srvcs})"
[ "${NTYPE}" != "OFW" ] && srvctst=(`${NCMD} "systemctl is-active ${srvcstotest}"`)
@@ -367,7 +370,6 @@ STATUS(){
if [ "${ST_ACTION}" != "check" ]; then
echo
echo -e "${idsCL[Green]} Docker Service(s) Status${idsCL[Default]}"
# echo -e "${idsCL[LightYellow]}----------------------------------------------------${idsCL[Default]}"
DIVIDER . green 52
fi
for docker in "${!dockers}"; do