Update mm-scripts.sh

This commit is contained in:
2023-03-25 13:21:11 -05:00
parent f7ad06ab63
commit 10c58f1964

View File

@@ -586,6 +586,7 @@ GETVPNINFO(){
} }
UPDATESERVICE(){ UPDATESERVICE(){
if [ "${1}" != "" ]; then
usrvc=${1} usrvc=${1}
echo "${usrvc} Update" > ${MMFOLDER}/mm.update.stop echo "${usrvc} Update" > ${MMFOLDER}/mm.update.stop
echo "$(date) - Updating Service (${usrvc}) : Starting" >> $logfile echo "$(date) - Updating Service (${usrvc}) : Starting" >> $logfile
@@ -647,6 +648,10 @@ UPDATESERVICE(){
echo echo
echo -e "${idsCL[Green]}${usrvc} Service has been updated${idsCL[Default]}" echo -e "${idsCL[Green]}${usrvc} Service has been updated${idsCL[Default]}"
else
echo -e "${idsCL[Red]}No service selected for update${idsCL[Default]}"
fi
} }
@@ -723,6 +728,10 @@ if [ ! -f ${MMFOLDER}/mm.update.stop ]; then
;; ;;
update);; update);;
update-service)
UPDATESERVICE ${2}
;;
clear) echo -e "${idsCL[LightCyan]}Clearing all mm.* files ${idsCL[Default]}" clear) echo -e "${idsCL[LightCyan]}Clearing all mm.* files ${idsCL[Default]}"
echo echo
;; ;;
@@ -733,6 +742,8 @@ if [ ! -f ${MMFOLDER}/mm.update.stop ]; then
echo -e " ${idsCL[Yellow]}start${idsCL[Default]} --> Start services" echo -e " ${idsCL[Yellow]}start${idsCL[Default]} --> Start services"
echo -e " ${idsCL[Yellow]}stop${idsCL[Default]} --> Stop services" echo -e " ${idsCL[Yellow]}stop${idsCL[Default]} --> Stop services"
echo -e " ${idsCL[Yellow]}restart${idsCL[Default]} --> Restart services" echo -e " ${idsCL[Yellow]}restart${idsCL[Default]} --> Restart services"
echo -e " ${idsCL[Yellow]}update-service <service>${idsCL[Default]} --> Update services"
echo
echo -e " ${idsCL[Yellow]}status${idsCL[Default]} --> Check Status on VPN and Media Services" echo -e " ${idsCL[Yellow]}status${idsCL[Default]} --> Check Status on VPN and Media Services"
echo -e " ${idsCL[Yellow]}vpninfo${idsCL[Default]} --> Show VPN Info" echo -e " ${idsCL[Yellow]}vpninfo${idsCL[Default]} --> Show VPN Info"
echo echo