Home Assistant installation documentation is geared primarily towards Raspberry Pi hardware. However, for my use case, I chose to setup on Docker since I already had Docker running on my Ubuntu Linux ‘home server‘ which hosts containers for all of my other services such as UniFi, Plex, MotionEye, etc. A good starting point for getting started with HA on Docker is with the official documentation here. I started this project over a year ago with the Docker run commands but my setup has been upgraded and expanded to include HASSIO and other add-on’s. I plan on scripting the setup for Docker compose soon.
I currently have 21 containers running in Docker. The majority are related to Home Assistant as I do have HASSIO and a number of add-on’s:
Many in the Home Assistant community are running their instances on NAS setups like Synology for the superior hardware specification. However, I have found that, even with the minimal specs on my current hardware, the performance and responses on my services are quite acceptable. The host OS is Ubuntu 20.04.1 LTS with an Intel(R) Core(TM) i3-8100 CPU @ 3.60GHz and 4GB RAM (yes, 4GB RAM!!). I have two Western Digital Red disk drives for the boot drive and storage (MotionEye videos, Plex movies, etc.) respectively. Even with all 21 containers running, server performance is acceptable:
As expected, the Motion daemon tends to consume the most CPU cycles. The only performance issue that I do run into occasionally is with Motion. Occasionally, I do see the process sucking up CPU cycles to the point where server response is sluggish. However, I believe this is related to the Motion daemon and how resources are allocated to the deamon. My understanding is that Motion will attempt to use all available resources unless hard limits are set. For the time being, I have reduced camera resolutions but my long term solution is to limit Motion to 2 CPU cores and < 50% CPU time.
Home Assistant is a fantastic project and works great in Docker. In general, I am strongly in favour of the Docker containerized approach for ease of management.