RTSPtoWebRTC icon indicating copy to clipboard operation
RTSPtoWebRTC copied to clipboard

WebRTC: ICE failed, add a TURN server and see about:webrtc for more details

Open crstian19 opened this issue 3 years ago • 3 comments

Hi, I made Dockerfile for this app and i run it in my server with traefik as reverse proxy. In LAN it works perfectly but when I try to run it in a public IP like VPS Server i've got this error:

WebRTC: ICE failed, add a TURN server and see about:webrtc for more details.

Looking for information I think that I need a to expose STUN ports.

https://www.html5rocks.com/en/tutorials/webrtc/infrastructure/ swappy-20210628_110339

crstian19 avatar Jun 28 '21 09:06 crstian19

got same error

rupadana avatar Oct 14 '21 03:10 rupadana

Common way to deal with this kind of problems is to set up your own dedicated TURN server.

You can try COTURN: https://gabrieltanner.org/blog/turn-server

Personally I prefer to stick to Golang stack and use Pion's excellent TURN implementation: https://github.com/pion/turn/blob/master/examples/turn-server/simple/main.go

You'll need to add you new TURN to PeerConnection config on client side: https://github.com/deepch/RTSPtoWebRTC/blob/master/web/static/js/app.js#L6

dbl0null avatar Oct 14 '21 05:10 dbl0null

Hi, I was wondering if I need to add the TURN credentials in both client and server side? And how can I add it on server side?

kumarbhupi avatar Nov 08 '23 15:11 kumarbhupi