Reverse proxy

In case of reverse proxy, what should be announce IP in server code
should it my original server IP or reverse proxy server ip

I think it should be that of the origin server, but just to be sure

mediasoup is not an http server.

You should stop proxying RTP traffic altogether. It’s not ideal or necessary for media streams like RTP in WebRTC, as it introduces unnecessary latency, breaks encryption, and disrupts the peer-to-peer architecture. Instead, use proper WebRTC signaling and, if needed, a TURN server to handle relaying in restricted network conditions.

HI Thank you for your responses. Let me brief you the entire structure.
I have a http server that is built with socket io, node… where I have media soup server library to create router , transports and producers and consumers.

This server lies behind a reverse proxy. I had to this for SSL certificate as i have multiple servers on multiple ec2 instances, or else chrome wont allow microphone access.

I set the announce IP as the main server IP
All the signalling communication happens via the reverse proxy.

And it is working fine.

@mactovish how did you manage know where to distribute the traffic, you said you have multipule mediasoup servers and a proxy in-front of them, how do you know which traffic is going to which server?