mirror of
https://github.com/alexbelgium/hassio-addons.git
synced 2026-05-30 04:14:04 +02:00
Update 30-monitoring.sh
This commit is contained in:
@@ -115,7 +115,8 @@ while true; do
|
|||||||
if [[ "$state" != "active" ]]; then
|
if [[ "$state" != "active" ]]; then
|
||||||
log_yellow "$(date) INFO: Restarting $service service"
|
log_yellow "$(date) INFO: Restarting $service service"
|
||||||
sudo systemctl restart "$service"
|
sudo systemctl restart "$service"
|
||||||
wait 5
|
sleep 5
|
||||||
|
state="$(systemctl is-active "$service")"
|
||||||
if [[ "$state" != "active" ]]; then
|
if [[ "$state" != "active" ]]; then
|
||||||
log_red "$(date) WARNING: $service could not restart"
|
log_red "$(date) WARNING: $service could not restart"
|
||||||
apprisealert "$service cannot restart"
|
apprisealert "$service cannot restart"
|
||||||
|
|||||||
Reference in New Issue
Block a user