I would like to make bulk restart possible. How can I call all the Restart buttons which blongs to ESPHome devices without listing each device one by one? In case of adding new ESPHome device later, I’d like that to be included automatically as well in the “Restart All ESP” action.
As you can see, the Restart button is already there. How should I configure the automation to run against all the ESPHome device’s Restart buttons without adding them one by one?
Sorry - yes I see you have the restart button - it’s late here…
No I can’t think of a way that would be any different to adding them to an automation. You could probably assign them a label and have a generic automation that acts on that - but no different to adding them manually…
I confirmed the automation was triggered but did not rebooted the ESPs which restart buttons were labeled. Also tried to set the label on the ESPHome device as well without luck.
Just create a regular automation where the action you want to perform is " Button ", then " Press ", then Choose entity. A list will appear of all the buttons you can push in your environment, select the various ESP reboot buttons you have defined
The issue is the OP wanted to find a way where he did not have to pick each device separately and more importantly not need to remember to add any new devices to the automation. Sort of like how a device class works.
Understood. I went with a quick and easy solution as ( to my mind anyways ) adding a new reboot entity ( from a newly added device ) to an existing automation isn’t much effort.
That said, I liked the OP’s idea. So I cheated and turned to ChatGPT. It came up with the following. Create a script in the UI using YAML mode
This gave me the base of the solution. Thank you very much!
For future referece:
I have updated all of my ESP’s Restart button from Restart to ESP_Restart, to uniquely mark this restart belongs to an ESP device: