Update mm-scripts.sh

This commit is contained in:
2023-03-26 21:28:34 -05:00
parent 0a0cea5fe1
commit 9b2173a5c0

View File

@@ -330,7 +330,7 @@ PersistentKeepalive = 25" >> /etc/wireguard/${VPN_INTERFACE}.conf
tryupdate=false
cc=0
until [ "${checkport}" != "" ]; do
until [ "${checkport}" == "" ]; do
if [ ${cc} -eq 10 ]; then
if [ -f ${MMFOLDER}/mm.${srvc}.starting ]; then
msg="${srvc^} Service is not starting properly, will try and update"
@@ -434,10 +434,8 @@ MMSTOP(){
echo -en "${idsCL[LightCyan]}${msg}${spc} ${idsCL[White]}: ${idsCL[Default]}"
for srvc in "${SERVICES_CHECK[@]}"; do
checkport=$(lsof -Pi :${MM_SERVICE_PORTS[${srvc}]} -sTCP:LISTEN -t)
until [ "${checkport}" != "" ]; do
echo "$checkport - ${MM_SERVICE_PORTS[${srvc}]}"
sleep 5s
until [ "${checkport}" == "" ]; do
sleep 1s
checkport=$(lsof -Pi :${MM_SERVICE_PORTS[${srvc}]} -sTCP:LISTEN -t)
done
done