Notify when restart or update needed

Hi, everyone,
I want to do something similar to Update Button, where he has a button for updating. But, I would like it to send an email to me telling me that a restart is required, or that updates are available. This came about because I checked my HA a few minutes ago, and it has been in a “Restart Required” for two weeks and has multiple updates available.

So, my questions are 1) can I just alter the automation that piggyback3 came up with to send an email out? and 2) How would I configure the automation for situations when a restart is required? (I’m assuming there’s a sensor for that as well).

Have a great weekend. :slight_smile: