Wednesday, 19 October 2016

Getting HADashboard up and running on Jessie for use with Home Assistant

HADashboard is a very cool dashboard for use with Home Assistant. I’ve tested the installation process on a Raspberry Pi1 version B (yes I know) and although it took nearly a whole day to get working, work it does and by golly, does it look good. More info on GitHub here
  1. First step is to install docker on your Raspberry Pi if you have never done that before:
    curl -sSL | sh
  2. If you would like to use Docker as a non-root user, you should now consider adding your user to the "docker" group with something like:
    sudo usermod -aG docker pi
  3. Set Docker to auto-start:
    sudo systemctl enable docker
More info here and credit to Alex Ellis

Installing HADashboard for Home Assistant on Jessie
  1. Clone the Repository:
    Clone the hadashboard repository to the current local directory on your machine.
    git clone
  2. Change your working directory to the repository root. Moving forward, we will be working from this directory:
    cd hadashboard
  3. Install the hadashboard docker file:
    Raspberry pi needs to use a different docker build file so the build command is slightly different:
    docker build -f Docker-raspi/Dockerfile -t hadashboard . (Don’t forget the full stop (.) at the end. N.B This took 5hrs on a Pi1 B so be prepared to wait).
  4. Next, in the ./lib directory, copy the ha_conf.rb.example file to ha_conf.rb and edit its settings to reflect your installation, pointing to the machine Home Assistant is running on and adding your api_key.

    $ha_url = ""
    $ha_apikey = "your key"

    $ha_url is a reference to your home assistant installation and must include the correct port number and scheme (http:// or https:// as appropriate)
    $ha_apikey should be set to your key if you have one, otherwise it can remain blank.

    The file also contains example newsfeeds for the News widget:

    $news_feeds = {
      "Traffic" => "",
      "News" =>,

    You can leave these alone for now or if you prefer customize them as described in the News widget section here
  5. Make a copy of dashboards/example.erb and call it 'main.erb', then edit this file to reference the items you want to display and control and to get the layout that you want. Leave the original example.erb intact and unchanged so that you don't run into problems when trying to update using the git commands mentioned later in "Updating the Dashboard". Full instructions here
  6. In the directory /home/pi/hadashboard/hapush, copy the hapush.cfg.example file to hapush.cfg then edit it to reflect your environment. This is what mine looks like.

    ha_url = ""
    ha_key =
    dash_host = ""
    logfile = "/app/hapush/hapush.log"
  7. You are now ready to run the docker image.
    docker run --name="hadashboard" -d -v /home/pi/hadashboard/dashboards:/app/dashboards -v /home/pi/hadashboard/lib/ha_conf.rb:/app/lib/ha_conf.rb -v /home/pi/hadashboard/hapush:/app/hapush --net=host hadashboard (all in one line)

    You may need to double check your paths are correct for mapping to the dashboards, ha_conf.rb and hapush locations? These are for my Pi with a standard Jessie install.
  8. You should get back something like this meaning your container has at least started:
  9. You should now be able to go to <ipaddressofyourPi>:3030/main to see the example hadashboard. By default, if you do not append the /main it will load the example file <ipaddressofyourPi>:3030/example
  1. Test your docker instance:
    docker ps -a
  2. This should return:
    CONTAINER ID        IMAGE               COMMAND                  CREATED             STATUS              PORTS               NAMES
    0aac704f2093        hadashboard         "/bin/sh -c '/app/hap"   About an hour ago   Up 59 minutes                           hadashboard
    You need the “Container ID” for the next step.
  3. Using the container ID, inspect the logs:
    docker logs xxxxxxx (Transpose xxxxxxx with your container ID).
  4. To restart your docker container:
    docker restart <yourcontainerID>
  5. To check all of your file mappings and to make sure everything is supposed to be where it supposed to be, try this:
    docker exec -t -i <yourcontainerID> /bin/bash then,

    ls /app/hapush/ should give you:

    root@raspberrypi:/app# ls /app/hapush/
    hapush.cfg  hapush.cfg.example  hapush.log

    ls /app/dashboards should give you:

    root@raspberrypi:/app# ls /app/dashboards
    example.erb  layout.erb  main.erb
  6. Navigate to /home/pi/hadashboard/hapush/hapush.log using WinSCP to see what is going on. If everything is OK, there should only be two lines:

    2016-10-18 21:48:27,891 INFO Reading dashboard: /app/dashboards/main.erb
    2016-10-18 21:48:27,948 INFO Reading dashboard: /app/dashboards/example.erb
For the more adventurous out there that even know what a docker-compose.yaml file is, user @snizzleorg has provide some information on starting the docker containers using a better method. More info here

“I personally prefer docker-compose to create and run the images:
This is my docker-compose.yaml file for hadashboard:”
  build: Dockerfile-rpi
  restart: always
  net: "host"
    - '/etc/localtime:/etc/localtime:ro'
    - '/etc/timezone:/etc/timezone:ro'
    - '/etc/home-assistant/hadashboard/dashboards:/app/dashboards
    - '/etc/home-assistant/hadashboard/config/:/app/lib/
    - '/etc/home-assistant/hadashboard/hapush/:/app/hapush/

Good luck and may the force be with you.
Post your issues in GitHub here


  1. I'm looking to do this and don't really know what I'm doing so I was looking for a guy to like this. Issue I'm having is with the following step:

    Install the hadashboard docker file:
    Raspberry pi needs to use a different docker build file so the build command is slightly different:
    docker build -f Docker-raspi/Dockerfile -t hadashboard . (Don’t forget the full stop (.) at the end. N.B This took 5hrs on a Pi1 B so be prepared to wait)

    When I type that in my response back is cannot connect to the docker Daemon is the doctor Damon running on this host? Any idea what's going on there?

    1. Do you install Docker per steps 1, 2 and 3?

    2. This is a bit old, but for others in the future the docker commands must be run with sudo. Otherwise you will get the above error.

  2. Hmmm, Step 7 crashes for me, and of course, I don't know what I'm doing:

    Unable to find image 'hadashboard:latest' locally
    Pulling repository
    docker: Error: image library/hadashboard:latest not found.
    See 'docker run --help'.