This commit is contained in:
2023-07-04 11:09:40 -05:00
parent f53920a042
commit 3f8e796124
6 changed files with 199 additions and 197 deletions

View File

@@ -1,24 +1,24 @@
VERS='4.8.4-07032023'
VERS='4.8.6-07042023'
noheader=' service status-check nightlyrephp7.3-fpm,new backup report check checkcerts gitea update-nodes copynpmcerts singleservercheck update-dyndns '
CERT_DAEMON='/snap/bin/certbot'
FOLDER=/opt/idssys/nodemgmt
SCRIPT=${FOLDER}/nodemgmt-scripts.sh
TMPFOLDER=${FOLDER}/.tmp
LOGFOLDER=${FOLDER}/logs
LOGFILE=${LOGFOLDER}/logfile
NM_FOLDER=/opt/idssys/nodemgmt
NM_SCRIPT=${NM_FOLDER}/nodemgmt-scripts.sh
NM_TMPFOLDER=${NM_FOLDER}/.tmp
NM_LOGFOLDER=${NM_FOLDER}/logs
NM_LOGFILE=${NM_LOGFOLDER}/logfile
RENOTIFY=1800
[ ! -d ${TMPFOLDER} ] && mkdir ${TMPFOLDER}
[ ! -d ${LOGFOLDER} ] && mkdir ${LOGFOLDER}
[ ! -d ${NM_TMPFOLDER} ] && mkdir ${NM_TMPFOLDER}
[ ! -d ${NM_LOGFOLDER} ] && mkdir ${NM_LOGFOLDER}
declare -i errtime
NM_SRVCOPT=(start stop restart reload enable disable)
if [ -f ${FOLDER}/defaults.local.inc ]; then
if [ -f ${NM_FOLDER}/defaults.local.inc ]; then
declare -A NM_HOSTS
declare -A NM_SERVICES_CHECK
declare -A NM_DOCKERS_CHECK
@@ -35,7 +35,7 @@ if [ -f ${FOLDER}/defaults.local.inc ]; then
declare -A NM_SINGLESRVR_DOCKERS
declare -A NM_SINGLESRVR_IP
source ${FOLDER}/defaults.local.inc
source ${NM_FOLDER}/defaults.local.inc
IFS=,
LOCAL_SERVICES=(${LOCAL_SERVICES})
@@ -133,7 +133,7 @@ NM_BACKUP_ITEMS['fail2ban']=/etc/fail2ban
GET-CHECKCERT-DOMAINS(){
declare -A CHECKCERT_DOMAINS
IFS=$'\n'
for LINE in `egrep -v '(^#|^$)' ${FOLDER}/ssl-cert-check/ssldomains`; do
for LINE in `egrep -v '(^#|^$)' ${NM_FOLDER}/ssl-cert-check/ssldomains`; do
HOST=${LINE%% *}
PORT=${LINE#* }
IFS=" "