Trouble with RTSP feeds through HAPROXY and vips

I set up RTSP streams from my 3 cameras in uinifi video, so that I can stream them to my home assistant dashboard. I’m running both Home Assistant as well as Unifi Video on a kubernetes cluster, using HAProxy as a go-between to proxy to either host (Unifi video is using node ports, ignore that for now).

Basically, here’s my setup

Host: or .21 (depending on which node UFV is running on

UFV: IP (could change if pod moves/ restarts. unifi video is listening on 7447 for RTSP as well as 31447 for each node (so that traffic to 31447 of either node goes to 7447.

Haproxy: listening on (VIP) and port 7447. This then forwards to 31443 of the hosts (.20 and .21)

Unifi video shows the streams with the containers ip, so something like

If I put this into Home assistant’s camera config, it works and i can see images from the cameras. However, if I change to (so that I go through HAPROXY, and dont need to update the ip every time), i get no video. I originally tried loading into vlc, and tada…I get video, which tells me that haproxy works, but for some reason Home Assistant only works with the direct IP. I originally thought this was a Ubiquiti Unifi video problem, but running it through VLC tells me it might be a ffmpeg or HA problem. I’ve tried both using the hosts’s ip 192.168.20:31447, etc, but this also does not work.

Is there something that I’m missing here? VLC works, but ffmpeg/HA doesn’t seem to like going through a proxy.