This commit is contained in:
2023-11-05 14:17:54 -06:00
parent 69ac960a61
commit c600907ff1
3 changed files with 81 additions and 2 deletions

View File

@@ -1003,8 +1003,8 @@ SHUTDOWN_CRIT(){
}
SHUTDOWN_OFFSITE(){
if [ ! -f ${PW_FOLDER}/shutdown.offsite ]; then
SENDNOTICE "OFFSITE SHUTDOWN - POWER OFF/LOW!!" "Shutting down offsite host(s)" 1
for offsite_host in "${PW_OFFSITEHOSTS[@]}"; do
SENDNOTICE "OFFSITE SHUTDOWN - POWER OFF/LOW!!" "Shutting down '${PW_ESXI_HOST_NAMES[${offsite_host}]}'" 1
SHUTDOWN_SERVER ${offsite_host} &
done
touch ${PW_FOLDER}/shutdown.offsite