Update services.inc

This commit is contained in:
2025-05-28 09:04:21 -05:00
parent ae7d845f66
commit f8f7ccd377

View File

@@ -8,9 +8,7 @@ SINGLE_SERVER_SERVICE_CHECK(){
[ "${2^^}" == "START" ] && rm -f ${NM_TMPFOLDER}/.singleserver.${1^^}.primary
# rm -f ${NM_TMPFOLDER}/.singleserver*
echo "HERE: ${1^^} - ${RUN_NODE_IP} - ${NM_NODETYPES[${1^^}]} - ${NM_NODETYPES[${1^^}]}"
if [ ! -f ${NM_TMPFOLDER}/.skip ] && ([[ "$(declare -p ${1^^}_SINGLESRVR_SERVICES)" =~ "declare -a" ]] || [[ "$(declare -p ${1^^}_SINGLESRVR_DOCKERS)" =~ "declare -a" ]]); then
if [[ $(ip addr show $(ip route | awk '/default/ { print $5 }') | grep "inet" | awk '/inet/ {print $2}' | cut -d'/' -f1) == *${NM_SINGLESRVR_IP[${1^^}]}* ]]; then
# if [ ! -f ${NM_TMPFOLDER}/.singleserver.${1^^}.primary ] || [ $(expr $(date +%s) - $(stat -c %Y ${NM_TMPFOLDER}/.singleserver.${1^^}.primary)) -ge 300 ]; then