Expose USB dongle to Docker container

@Aqua1ung what do you try to do, I would say the daemon itself just need to have permissions to be able to access the device (which it most likely has)

I run this specific docker under an other linux, but its the docker or in my case docker-compose which needs the device mapping.
I do not recall that I needed to do any changes on the service or udev, but sure, you want to make sure
no other process tries to use your device and that docker and your containers auto start if you want them to.

In my case its a Dresden Elektrik Zigbee stick and I run it with a dedicated deconz container.
I map the /dev/ttyACM0 directly, but possibly the link might work as well, anyhow you would find the device

# ls -la /dev/serial/by-id/usb-dresden_elektronik_ingenieurtechnik_GmbH_ConBee_II_XXNNNNNN-zzzz 
lrwxrwxrwx 1 root root 13 Dec 29 00:32 /dev/serial/by-id/usb-dresden_elektronik_ingenieurtechnik_GmbH_ConBee_II_XXNNNNNNzzzz -> ../../ttyACM0

sniplet from the docker-compose.yaml

      - /dev/ttyACM0:/dev/ttyACM0
      - DECONZ_DEVICE=/dev/ttyACM0
1 Like