Ha on Vm unable to connect MQTT on docker

So heres the problem. My ha connection to my mqtt server fails every time. Heres the setup.

Ha (fresh install) running on qnap virtualization station. Bridged to network via virtual switch and I can ping it from other devices.
My MQTT broker is living on the same qnap as a docker install as host and port forwarded to the same virtual switch. I have few ruuvi software (another running on qnap docker and another on raspb) and they both connect to the mqtt broker just fine.

But when I try to connect from the ha to the broker the connection fails every time. On the mqtt broker I see the connection happening though. No fails no errors. But on the ha I always get this:

I dont believe its an authentication thing, because setting the broker “open” doesnt help. I dont also believe its a problem with the broker because the two ruuvi-software I have running are connecting just fine (at least to my knowledge).

Any ideas…?

You have different subnets (10.0.3.x and 192.168.1.x). Are they correctly talking to each other?

Just because it pings doesn’t mean all the protocols are connected and everything works. It only means ping works.

So very true. All those gadgets, all installed, ready and anxious to go, and not talking to each other…

Networking is layered. Each level underneath has to work before the next layer up can do so.

This is from my pi, checkin the connection to the mqtt server.

**


**

Thats why I was thinking its not a network problem if I can connet the mqtt server outside of the qnap itself.