Docker (on M1 Mac), I can access using Bridge but not Host mode?

Hey team, I’m new to Docker so this might be something obvious that I’m missing.

I have a yeelight that I’m looking to test out diyHue with. I have a rpi2b here but I’m just looking to get diyHue running in a familiar environment before I push on there.

I can get the docker container running in both host and bridge mode:

docker run -d --name diyHue --restart=always --network=host -e MAC=MYMACADDRESS -v /mnt/hue-emulator/config:/opt/hue-emulator/config diyhue/core:latest 

docker run -d --name diyHue --restart=always --network=bridge -v /mnt/hue-emulator/config:/opt/hue-emulator/config -e MAC=MYMACADDRESS -e IP=MYIPADDRESS -p 80:80/tcp -p 443:443/tcp -p 1900:1900/udp -p 2100:2100/udp -p 1982:1982/udp diyhue/core:latest

Looking at the docker logs, everything is coming up well enough, with the final log saying the server is running and providing the IP address. All good so far.

But, I can only access the web interface when I’m using the bridge version. That also means that the diyHue node (? I assume it’s called a node) shows up in my hue app when I’m running in bridge mode.

I’d be happy to push on with bridge mode, except my yeelight doesn’t show up! This github issue suggests that it’s because of the way yeelights are discovered, and I should be using host mode to proceed (or, apply some complicated fixes I don’t understand right now)

So, to get to my point - I’m trying to access the web interface of diyHue running in docker ‘host’ mode. There’s a good chance I’m just missing something obvious with my Docker config. Please help!

You know what? I’m seeing here in the docker docs (Use host networking | Docker Documentation)

“The host networking driver only works on Linux hosts, and is not supported on Docker Desktop for Mac, Docker Desktop for Windows, or Docker EE for Windows Server.”

If that’s it, can I just get a confirmation and I’ll push on with my rpi build? (Seems odd that the preferred networking mode isn’t available on anything but linux, I thought the point of docker was to be platform agnostic!)


I would recommend the Rpi build for your scenario.
Datacenters etc are all (majority) running Linux. Basically only Endusers are into Windows and Mac world, hence the stack support.

Same issue here

you could follow the MACvLan approach but i guess you are faster with the Rpi build it can also run 247/7 with lower power consumption.