Update nodemgmt-scripts.sh

This commit is contained in:
2022-07-24 19:01:35 -05:00
parent 5d8e236258
commit e312d820e5

View File

@@ -1831,6 +1831,12 @@ RUN_COMMAND(){
}
DOWNLIST(){
if [ "${1}" = "report" ]; then
unset idsCL idsBG idsST
idsCL=('')
idsBG=('')
idsST=('')
fi
declare -i cw; declare -i spc1; declare -i c
#rm -f /tmp/ssllist
#for downitem in /opt/idssys/nodemgmt/*.down ; do echo $downitem; done > /tmp/downlist
@@ -1943,7 +1949,7 @@ if [ ${action-x} ]; then
update-nodes) NODEUPDATE ${2};;
update-dyndns) UPDATE_DYNDNS ${2};;
backup) BACKUP;;
downlist) DOWNLIST;;
downlist) DOWNLIST ${2};;
status)
if [ -f "${FOLDER}/status-check.running" ]; then
fd=`stat --format=%Y "${FOLDER}/status-check.running"`
@@ -1956,6 +1962,7 @@ if [ ${action-x} ]; then
rm -f ${FOLDER}/status-check.lastrun
STATUS report > ${FOLDER}/status-check.lastrun
if [ "${3}" = "email" ] && [ "${STATUS_CHECK_EMAIL}" != "" ]; then
DOWNLIST report > ${FOLDER}/status-check.lastrun
STATUSLOG="$(cat ${FOLDER}/status-check.lastrun)"
echo "Status Report\n\n${STATUSLOG}" | mail -s "Status Report" david@schroedercity.com
echo "Status Report\n\n${STATUSLOG}" | mail -s "Status Report" 9208839613@mms.att.net