Unfortunately I have a relatively unstable internet connection which requires me to restart my router quite often (need to by a new one at some point).
Whenever I restart the internet connection my Home assistant on my raspberry looses the connection and also needs to be restarted. This is particularly bad if i am not at home and my set-up stops working.
Is there a way to automatically restart home assistant after say 5 min of no internet connection?
I am just starting down the road of Home Assistant on my RPi. I have only had it a week.
What method did you use to install Home Assistant? I think the officially recommended method is to use the Hassio (HassOS) image on an SD Card. When I tested that in a VM, it periodically lost network connectivity. I am using another method on my Raspberry.
you can use an automation to do what you want. Youâll need to create a âpingâ binary sensor. then you can use this (after substituting your details):
automation:
- alias: restart home assistant
trigger:
- platform: state
entity_id: binary_sensor.your_sensor_name
to: 'off'
for:
minutes: 5
action:
- service: homeassistant.restart
yeah, i guess there are âofficialâ methods but I was referring to the idea that Hassio was the only âofficialâ method. I should have been more specific.
Hass.io can be installed on Linux, not just RPi. Hass.io can be installed on Raspian without HassOS.
Hassbian can also be installed on Debian based Linux
Of course, all 3 variants can be installed in VMs.
These are variations I listed above should be easily supported too.
Did you click the link and read whatâs there? Did you then click the Hass.io link and read it?
All the things you mentioned about Hass.io are supported by the documentation. Hassbian technically is Raspbian + Home Assistant, but yes, the scripts will work on Debian and Ubuntu.
The key thing is, weâre talking about what the documentation supports, and what the core components will work on. The project doesnât promise that the documentation will support (say) installing Home Assistant on Fedora, or that all the components will work on (say) Windows Server 2019. However, Docker, Hass.io (whether HassOS or other), and Hassbian, those are different.
Your listing link did not mention #1.
When I did #2 I had to modify the Linux install
For #3 I needed to hunt down the released .deb for Hassbian & troubleshoot dependencies.
Your listing link only recommended one choice for VMs.
I am moving to Hassbian on Raspian to gain more customization flexibility that the Docker based installations.
Docker on Raspbian is pretty much the most flexible way you can install HA (Hassio or not) on a RPi.
I can definitely see the increased flexibility if you are moving from HassOS to Hassbian but if you are on a regular Docker install now Iâm not sure what âflexibilityâ gain you would realize.
And any way you install HA following any of the recommended install methods you will ultimately end up with essentially the same product (aside from the add-on capability of hassio). In the end itâs all just âHome Assistantâ.
The problem is is you need to add python components, they get replaced on upgrade with the container. That does not happen in a virtualenv like Hassbian.
I am confused, what python components do you need to add for docker install?
i have been running HA on docker for over a year and havenât had to install anything extra python wise.
hass.io installed in docker on raspbian or debian or ubuntu will give you ultimately the best of everything IMO. I would never go back from docker anyway⌠itâs way easier to manage and use.
The Alexa media player requires the alexapy Python module for some of its functionality. With Hassio you need to reinstall after every update since the docker container is replaced.