From bb5bbe2693e502e08ee06f372d60e7b81ed30572 Mon Sep 17 00:00:00 2001 From: Bram Prieshof Date: Fri, 5 Jun 2020 01:28:55 +0000 Subject: [PATCH] 'Bash/Pinger/Dual-IF-Ping.sh.example' updaten --- Bash/Pinger/Dual-IF-Ping.sh.example | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Bash/Pinger/Dual-IF-Ping.sh.example b/Bash/Pinger/Dual-IF-Ping.sh.example index 2b26fc3..4ad6eb8 100644 --- a/Bash/Pinger/Dual-IF-Ping.sh.example +++ b/Bash/Pinger/Dual-IF-Ping.sh.example @@ -1,6 +1,6 @@ #!/bin/bash -#Trigger form Cron +#Trigger form Cron */5 * * * * root bash > /dev/null 2>&1 # Set Parameters domoticzserverip='127.0.0.1:8080' if1='' @@ -88,7 +88,7 @@ domoticzstatus2=$(curl -s "http://"$domoticzserverip"/json.htm?type=devices&rid= # Compare ping result to Domoticz device status if [ "$device2" != "$domoticzstatus2" ] ; then -if [ "$device1" = On ] ; then +if [ "$device2" = On ] ; then curl -s "http://"$domoticzserverip"/json.htm?type=command¶m=switchlight&idx="$IDX2"&switchcmd=On" 2>/dev/null 1>/dev/null else curl -s "http://"$domoticzserverip"/json.htm?type=command¶m=switchlight&idx="$IDX2"&switchcmd=Off" 2>/dev/null 1>/dev/null