I’ve been using home assistant in a virtual machine on my home server for almost a year now. It rellay is a great piece of software for home automation with almost limitless possibilities. However I’ve decided to move it to hass.io on a raspberry pi mainly because of some additional features. On the rapberry I can directly use the bluetooth module needed for some sensors. And hass.io offers some need add ons like a server to control Amazon’s FireTV stick or my USV. Except the more limited CPU I couldn’t find any drawbacks so far. Hass.io is basically a very slim linux running home assistant and some other useful tools in docker containers which you can control from home assistant’s gui.
Installation of the base system is very simple. Download the latest release image from homeassistant.io for your device. Then dump the image to a sd card:
sudo dd if=resinos-hassio-1.1-raspberrypi3.img of=/dev/sdc
Watch out for the correct device identifier (
/dev/sdc in my case). Using the wrong identifier might erase your system! For operating systems other than linux you will need to use different tool for this.
Insert the SD card into the raspberry and have it boot for the first time. This will take some time as the docker images have to be pulled. After around 20 minutes you should be able to reach your hass.io instance at http://hassio.local:8123.
Install some useful addons
There is a quite long list of add ons available for home assistant already. With these you can add extra functionality like a database, a mqtt broker and so on. Even more add ons are available from community repositories.
I’ve started with only a few add ons. Most of the others I don’t nees as I already have servers running providing DHCP, letsencrypt SSL proxying, mqtt broker and so on. Others I might add once I need their funtionality.
To access your home assistant configuration remotely it makes sense to install either the SSH add on or the Samba addon (windows file share). In my linuxy environment I prefer SSH a lot. Installation is simple again and can be done from the GUI. Go to the hass.io tab, click on the shopping bad oin the upper right corner and select the SSH Server add on from the list. Then install it. Configuration isn’t complex either. Just copy your puplic ssh keys into the list of authorized keys in the options box, save and restart. You now should be able to connect to your hass.io instance by ssh.
You now have an
ash shell at your disposal.
This add on is necessary if you want to make use of your raspberry’s bluetooth adapter. Simply install it from the GUI and start it.
As I prefer editing the *.yaml files of my configuration directly not using the GUI editor, I’ve also installed the configurator add on. This allows you to edit the text files in your browser using something like a standard text editor with syntax highlighting. Aditionally it includes lists of available triggers, events, entities, conditions and services and allows reloading parts of your configuration as well as restarting home assistant.
Installation is done using the GUI as with all other add ons. In the options you have to set up a username and a password to protect your configuration. You can also limit the IP adresss of devices having acces to the configurator. It might be a good idea to exlude your kids here. Make sure the ‘allowed_networks’ aip pattern fits to your network. In most cases it should do as it’s preset to the most popular private network block
192.168.0.0. The configurator’s UI should now be available at http://hassio.local:3218.
Now it’s time for me to move over all my existing devices and configuration to the new home assistant instance.