Installation of ZHA in docker environment

Hi

I am trying to setup ZHA with a Sonoff Zigbee 3.0 USB dongle Plus stick. No luck.

My HA instance is running in a docker-compose environment with the following setup.

First I am adding ZHA

This gives the following result
stag2

Accepting gives this as next step and I selecting ZNP

After saving I get this menu as result.

And finally

The red error text says “Unable to connect to ZHA device”

Somewhere, something must be wrong, I am unable to see it, after hours googling and trying different approaches found on internet.

Any fresh eyes that can help?

Try adding

privileged: true

and maybe adding the usb device.
Here is my compose file for reference as I also have the same Zigbee device…

version: '3.3'
services:
    home-assistant:
        privileged: true
        restart: always
        container_name: home-assistant
        volumes:
            - /home/pcwii/homeassistant:/config
            - /var/run/docker.sock:/var/run/docker.sock
            - /dev/serial/by-id:/dev/serial/by-id
            - /run/dbus:/run/dbus:ro
        environment:
            - TZ=america/toronto
            - PUID=1000
            - PGID=1000
            - UMASK=007
        devices:
            - /dev/ttyUSB0:/dev/ttyUSB0
            - /dev/ttyUSB1:/dev/ttyUSB1
        network_mode: host
        image: homeassistant/home-assistant:stable
        logging:
            options:
                max-size: "10m"
1 Like

May i ask offtopic for what kind of integration do you use access to Docker socket (/var/run/docker.sock:/var/run/docker.sock)? Thank you.

Monitor docker.

1 Like