Home Assistant Supervised Installation

Dec 5, 2022 · 4 mins read
Home Assistant Supervised Installation

In the video below, we show you how to do a Home Assistant Supervised Installation


There are lots of different ways to install Home Assistant

Personally I prefer to run this in a VM because you can take a snapshot prior to upgrades and rollback if things go thing wrong

Also, if you run this on say a Raspberry Pi for instance and that stops working, you’re home automatation will be out of service while you source a replacement computer and then restore Home Assistant

With a VM though, you can run it on another hypervisor until you can replace the broken computer

Although you can download and install Home Assistant as a pre-built VM, another option is to do a supervised installation

This involves instaling Home Assistant onto a Debian OS which brings the extra benefit of being able take advantage of features in Linux such as USB over IP for instance

Useful links:
https://www.home-assistant.io/installation/linux/#install-home-assistant-supervised
https://github.com/home-assistant/architecture/blob/master/adr/0014-home-assistant-supervised.md
https://github.com/home-assistant/os-agent/releases

Assumptions:
It is assumed that you already have a hypervisor to run this on, but Proxmox VE is recommended
As even the FBI warn, security is something you need to take seriously with smart home devices
While you can use a software firewall like UFW on a Debian computer, Proxmox VE also provides a firewall option
The benefit of using the firewall in Proxmox VE is that’s independent of the VM, meaning only a Proxmox administrator can make changes to it
It also avoids some of the complications of the extra rules required to support Docker for instance

Steps Taken:

  1. Debian OS
    Debian OS is supported so you need to create a VM with Debian installed
    This should either have a static IP address or a reserved IP address in DHCP
    By default, there is no support for sudo so switch to root

    su -  
    And make sure the OS is up to date
    apt update && apt upgrade -y  

  2. Install Dependencies

    apt install apparmor jq wget curl udisks2 libglib2.0-bin network-manager dbus systemd-journal-remote -y  
    This can take a while

  3. Install Docker-CE
    The Docker Community Edition is supported so install this

    curl -fsSL get.docker.com | sh  
    This can take a while

  4. Install HA OS Agent
    The OS agent for HA needs to be installed to allow communication with the OS
    TIP: Check for the latest version
    https://github.com/home-assistant/os-agent/releases

    Download and install the package

    wget https://github.com/home-assistant/os-agent/releases/download/1.4.1/os-agent_1.4.1_linux_x86_64.deb  
    dpkg -i os-agent_1.4.1_linux_x86_64.deb  
    TIP: Copy the URL in the web browser

  5. Install HA Supervised Download the package

      
    wget https://github.com/home-assistant/supervised-installer/releases/latest/download/homeassistant-supervised.deb -O homeassistant-supervised.deb  
    The -O parameter is to overwrite the existing file, if it exists, otherwise you’ll just keep downloading an extra file but install the first version that was first downloaded

    Install the package
      
    dpkg -i homeassistant-supervised.deb  
    Now reboot the computer

  6. Onboarding With the installation complete and the computer back up and running, point your web browser to port 8123 of the computer
    E.g. http://192.168.100.20:8213

    NOTE: At this stage, HTTPS is not available
    Wait for the HA wizard to become available and then follow the process

  7. Updating Home Assistant
    Assuming the computer is a VM, delete any previous snapshots then create a new one before performing an update. If anything goes wrong you can then revert to the working instance
    To update Debian use the normal apt update && apt upgrade process. Reboot the host from within the HA GUI if a reboot is suggested
    To update Home Assistant Core you can do this as normal in the GUI whenever an update is announced. The update process will do a reboot automatically
    Add-ons and integrations can be updated as normal as well
    To update the OS agent, check for the latest version and then download and install that using the previous steps. This will overwrite the existing version. Reboot the host from within the HA GUI
    If a Supervisor update is required, download and install that using the previous steps. This will overwrite the existing version if the -O option is used. Reboot the host from within the HA GUI

  8. Troubleshooting For problems check the logs in HA or check the operating system logs

      
    journalctl -f

Sharing is caring!