rtsp relay to other server
470
📡 RTSP Proxy (Fanout to Multiple Nodes)
A lightweight RTSP Proxy server written in Go, powered by gortsplib/v5. It acts as a bridge between RTSP clients and servers, with the ability to fanout streams to multiple destination nodes.
⸻
✨ Features • Accepts client connections and handles RTSP methods (OPTIONS, DESCRIBE, SETUP, PLAY, TEARDOWN). • Proxies and forwards requests to multiple RTSP backend nodes. • Fanout streaming to distribute load across multiple servers. • Simple and extensible code base.
⸻
🚀 Usage
docker pull thangdq88/rtsp-proxy:latest
docker run -d
--name rtsp-proxy
-p 8554:8554
-e DEST_NODES="rtsp://node1:8554/live/stream,rtsp://node2:8554/live/stream"
thangdq88/rtsp-proxy:latest
• -p 8554:8554: expose RTSP port.
• DEST_NODES: list of destination RTSP nodes, separated by ,.
⸻
⚡ Quick Test
Publish a stream
ffmpeg -re -i input.mp4 -c copy -f rtsp rtsp://localhost:8554/live/test
Play from proxy
ffplay rtsp://localhost:8554/live/test
⸻
🔧 Environment Variables
Variable Default Description DEST_NODES (empty) Comma-separated list of RTSP destination nodes PORT 8554 RTSP listening port
⸻
⸻
📝 Notes • This is an initial demo/PoC implementation. • Advanced error handling and reconnect logic are not yet included. • Great as a base for learning or building larger-scale RTSP fanout systems.
Content type
Image
Digest
sha256:7fbfb323f…
Size
60.4 MB
Last updated
about 1 year ago
docker pull thangdq88/rtsp_proxy