Hi
I want to reboot my Asuswrt router when the 2.4hz radio fails. I’ve got the Asuswrt integration working and its tracking devices using 2.4hz radio, so the automation is tracking a entity which is using that radio
I’ve also install the SSH keys so HA can SSH into the remote router without a password
I’ve created a few automation conditions but cannot get the action correct in the GUI or even the YML editor
Here is the automation.yaml file
- id: '1673906360178'
alias: Reboot Router
description: ''
trigger:
- platform: state
entity_id:
- device_tracker.garage_door
from: home
to: away
condition: []
action: []
- service: /config/reboot.yaml
I then started to create a shell_command script here
reboot_router: ssh -l admin 192.168.0.1 "reboot"
Then the main reboot.yaml file
reboot_router:
alias: Reboot Router Script
sequence:
- service: shell_command.reboot_router
But I’m struggling to put it all together to create an automation. Can someone help please ?
Thanks