Update nodemgmt-scripts.sh

This commit is contained in:
2023-12-11 08:25:06 -06:00
parent fde62b487c
commit 5fb863019b

View File

@@ -635,8 +635,8 @@ DOWNLIST(){
else
echo -e "${idsCL[LightGreen]}Current List of Items Down...${idsCL[Default]}"
DIVIDER false yellow 110
if [ "${1}" != "report" ]; then
echo -e "${idsCL[Yellow]}Service/Host Host Down_Time${idsCL[Default]}"
if [ "${1}" == "report" ]; then
echo -e "${idsCL[Yellow]}[Type] [Host/Service/Docker Name] [Host] [Down_Time]${idsCL[Default]}"
else
echo -e "${idsCL[Yellow]} [Type] [Host/Service/Docker Name] [Host] [Down_Time] [Notifications]${idsCL[Default]}"
fi
@@ -685,9 +685,9 @@ DOWNLIST(){
until [ $c = ${spc1} ]; do spca="${spca} "; c=`expr $c + 1`; done
c=0; spc2=''; spc1=${cw2}-${#host}
until [ $c = ${spc1} ]; do spc2="${spc2} "; c=`expr $c + 1`; done
if [ "${1}" != "report" ]; then
echo -e "${idsCL[LightRed]}${itemname}${spc}${host}${spc2}$(SHOW_TIME ${toterrtime})${idsCL[Default]}"
time=$(SHOW_TIME ${toterrtime})
if [ "${1}" == "report" ]; then
echo -e "${idsCL[LightRed]}${itemtype}${spca}${itemname}${spc}${host}${spc2}${time}${idsCL[Default]}"
else
if [ "${choice}" -gt 0 ] 2>/dev/null && [ ${is} -eq ${choice} ]; then
[ ! -f ${NM_TMPFOLDER}/${ditem}.disable ] && touch ${NM_TMPFOLDER}/${ditem}.disable || rm -f ${NM_TMPFOLDER}/${ditem}.disable
@@ -695,9 +695,7 @@ DOWNLIST(){
[ ${is} -lt 10 ] && ignsel=" ${is}) " || ignsel="${is}) "
[ -f ${NM_TMPFOLDER}/${ditem}.disable ] && dstatus="OFF" || dstatus="${idsCL[Green]}ON"
time=$(SHOW_TIME ${toterrtime})
c=0; spc3=''
until [ $c = `expr 26 - ${#time}` ]; do spc3="${spc3} "; ((c++)); done
c=0; spc3=''; until [ $c = `expr 26 - ${#time}` ]; do spc3="${spc3} "; ((c++)); done
echo -e "\033[K${idsCL[LightRed]}${idsST[Bold]}${ignsel}${idsST[Reset]}${idsCL[LightRed]}${itemtype}${spca}${itemname}${spc}${host}${spc2}${time}${spc3}${dstatus}${idsCL[Default]}"
fi