Update powerwall.sh

This commit is contained in:
2023-12-11 16:28:14 -06:00
parent 0a1d475f02
commit f8bf207af4

View File

@@ -1108,15 +1108,14 @@ POWERLOGGER_SERVICE(){
done done
fi fi
fi fi
done done
if [ "$(compgen -G "${PW_TMPFOLDER}/temp.*")" != "" ] || [ "$(compgen -G "${PW_TMPFOLDER}/power.*")" != "" ]; then if [ "$(compgen -G "${PW_TMPFOLDER}/temp.*")" != "" ] || [ "$(compgen -G "${PW_TMPFOLDER}/power.*")" != "" ]; then
sleep 1m sleep 1m
else else
sleep 5m sleep 5m
fi fi
done done
} }
@@ -1177,14 +1176,14 @@ CHECK_SERVICES(){
SHUTDOWN_MAIN(){ SHUTDOWN_MAIN(){
if [ "${1}" == "ServerRoomTH"] || [ "${1}" == "TEMP"]; then if [ "${1}" == "ServerRoomTH"] || [ "${1}" == "TEMP"]; then
# SHUTDOWN_SERVERS MAIN ${1} SHUTDOWN_SERVERS MAIN ${1}
HOSTMGMT main -e off >/dev/null 2>&1 # HOSTMGMT main -e off >/dev/null 2>&1
reason='Server Room Overheated!' reason='Server Room Overheated!'
sendnotice=true sendnotice=true
elif [ "${1}" == "POWER"]; then elif [ "${1}" == "POWER"]; then
# SHUTDOWN_SERVERS MAIN ${1} SHUTDOWN_SERVERS MAIN ${1}
HOSTMGMT main -e off >/dev/null 2>&1 # HOSTMGMT main -e off >/dev/null 2>&1
reason='Low Power!' reason='Low Power!'
sendnotice=true sendnotice=true
@@ -1202,14 +1201,14 @@ ${reason}" 1
} }
SHUTDOWN_SYS(){ SHUTDOWN_SYS(){
if [ "${1}" == "ServerRoomTH"] || [ "${1}" == "TEMP"]; then if [ "${1}" == "ServerRoomTH"] || [ "${1}" == "TEMP"]; then
# SHUTDOWN_SERVERS SYS ${1} SHUTDOWN_SERVERS SYS ${1}
HOSTMGMT sys -e off >/dev/null 2>&1 # HOSTMGMT sys -e off >/dev/null 2>&1
reason='Server Room Overheated!' reason='Server Room Overheated!'
sendnotice=true sendnotice=true
elif [ "${1}" == "POWER"]; then elif [ "${1}" == "POWER"]; then
# SHUTDOWN_SERVERS SYS ${1} SHUTDOWN_SERVERS SYS ${1}
HOSTMGMT sys -e off >/dev/null 2>&1 # HOSTMGMT sys -e off >/dev/null 2>&1
reason='Low Power!' reason='Low Power!'
sendnotice=true sendnotice=true