Configuring Home Assistant in your Campervan

Articles

Configuring Home Assistant in your Campervan

We talk you through some common and useful configurations for your fresh Home Assistant installation.

So you have installed Home Assistant or maybe purchased a Home Assistant Green with it pre-installed and you want to know what’s next. Before added all your automations, sensors and all the fun stuff, it is a good time to ensure your HA is setup securely and well configured ready for the future.

Throughout this article and future articles we will always refer to the following glossary terms:

  • HA OS - Full Home Assistant Operating System.
  • HA Core - Just the Home Assistant app designed for use with containers.

Welcome Screen

Depending upon the type of install you have performed, you can now visit your initial welcome screen. If you have used the HA OS then it will typically be http://home-assistant.local:8123 or if you have installed it in a container as we have for this demo, then you won’t be using the DNS created by the install. but a manual ip address and possibly a different port.

Welcome Screen

We are not performing a restore, so click on “Create my Smart Home”.

Create User

Create User

Now it is time to create the first user, probably the only user. Enter your name, user and password details and click Create Account.

Location

Location Location2

Next you are requested to choose your home location. Depending upon your vanlife status you may not have one or maybe its a family location you use for “home”. I have some automations so it updates the home as I travel and stop.

Diagnostics

Diagnostics

We recommend total privacy, so always leave these all off.

Devices

Devices

Any devices will then be discovered. This is typically very few as no other protocols or coordinators have been setup yet. Click on Finish.

Overview

Overview Dashboard

That’s it, the initial onboarding is now complete and you are presented with your first dashboard, the Overview dashboard.

Advanced Mode

Click on your user in the bottom left, scroll down and ensure Advanced mode is slid across. This will ensure all the menu options are presented in further screens and nothing is hidden from you.

Advanced Mode

Backup

Settings

System

Backups

Click on Settings and then System, then Backups.

Backup Encryption

Click Setup Backups. You will be given an encryption key. Take note of this, you will need it if you ever have to restore your system. Then click Next.

Backup Type

It is very important to get some backups running regularly, at the start it maybe OK to choose the Automatic option, this will perform daily backups locally and keep 3 backups. Click on Recommended.

First Backup

Congratulations you now have your first backup and can see 1 backup under the Automatic Backup section. At least are making daily backups and keeping a few. Click on Config Backup Settings.

Backup Settings

Consider increasing the default 3 days to maybe 7, you probably have the space.

Backup Locations

External Locations

Another option is to do a separate backup to an external device. Click on Explore More Locations. If you have a OneDrive account or one of the others consider adding it too. Your backups will at least be in multiple locations. Remember the backups are encrypted so relatively safe.

Downloading HACS if in a Container

The Home Assistant Community Store (HACS) is a great resource and no doubt you will use it to download many custom cards, themes and other items in the future configurations. HACS is automatically available for install when using HA OS, but not if running HA Core. We need to download it if running in a container so that it appears on the list for installation.

Open a console into your linux container and type the following:

 wget -O - https://get.hacs.xyz | bash - 

HACS download

We use a product called Portainer to manage the docker containers and it has a console option to allow commands to be entered easily. As stated in the output above you will need to restart Home Assistant.

To restart, click on the Developer Tools option in the lower left.

Developer Tools

There are a couple of restart options, a full restart and a quick reload. The full restart is exactly that and the web interface will become unavailable and then all the integrations and entities restarted. Most of the time the config reload is adequate, for this one, choose the full restart.

Restart

Installing HACS

If you are using HA Core, you have followed the above step and HACS will appear when you follow the next few steps.

Settings

Integrations

Click on Settings, then Device and Services. You are then presented with the Integrations screen, again this is a screen to get very familiar with. All the future main devices and protocols will be entered here. The first integration to add is HACS. Click on Add Integration.

HACS

HACS Activation

Select HACS and you will then be presented an activation screen. Home Assistant is an open source product and so are most of the integrations. GitHub is the home of open source and therefore you will need an account in Github in order to activate HACS. It is also very useful for future integrations that you may want to download direct from GitHub. Take a note of the code.

Login to Github or create an account, then proceed with the activation.

GitHub

Activation

Enter Code

Confirm

All Done

Once done, return to the Home Assistant window and HACS will be installed.

HACS Confirmation

HACS Installed

HACS now appears on the sidebar on the left.

Setup Packages

Behind the scenes, Home Assistant uses YAML format files to store much of the configuration. This allows developers and users an alternative way to manage the configuration without having to use the user interface. If you know the exact format of the YAML text this is great. All our Sensa integrations are offered by supplying YAML files, either ESP YAML file or Home Assistant YAML files. Home Assistant has a main configuration.yaml file which resides in its main \config directory. However if you were to add all your sensors to this one file it would soon get out of hand. For this reason Home Assistant has a feature called packages.

Simply create a folder called packages under the config directory. Then create a folder called blackpaw. Our recommendation is to then place all our Home Assistant integration files into this directory. This keeps our files separate from others you may create and allows you to easily just replace them when we publish new versions.

To enable the packages feature, edit the configuration.yaml file and add the packages line in the homeassistant section as below:

homeassistant:
  packages: !include_dir_named packages

Don’t forget to restart Home Assistant to pickup the changes, the Quick Reload option is fine as it will just reload all the yaml files.

Conclusion

Home Assistant now has a basic configuration, you have installed HACS and setup some backups. This provides a solid platform to continue forward with further configurations.