Hi all!
I’m having HA running as a docker container, started with the provided docker compose file: Alternative - Home Assistant
I’m also having running an Mosquitto MQTT broker as a docker container, which is listening to port 1883/TCP.
When the MQTT integration is about to be set up (either in frontend or via configuration.yaml), HA hangs up. In frontend it’s quite obvious because the circle keeps spinning for minutes (then I aborted). When I configure it via configuration.yaml and restart HA, it’s not coming back, so I only see “connection lost”.
As MQTT broker address I tried:
- localhost
- 192.168.1.xx (private IP address of RPi in my LAN)
- 172.17.0.3 (IP address of the Mosquitto container)
- It’s neither working with the public test.mosquitto.org server
Nothing works, the same problem as described occurs with all given addresses. While the integration is “setting up”, no log entries are created not even with
logger:
default: debug
The MQTT broker works properly, I can access it both from the RPi and from other LAN devices.
Since the HA container runs with the host
network setting, there shouldn’t be any problem with connection (especially with the iptables
where 1883 is allowed), right?
I’m quite desperate because I have no idea what else could cause this problem - do you have any idea why HA can’t connect to the MQTT broker?
Many thanks in advance!