From a97d46f19659447b449ff54c09781c6c9755e3f9 Mon Sep 17 00:00:00 2001 From: Nicolas Mowen Date: Sun, 5 Nov 2023 04:19:21 -0700 Subject: [PATCH] Fix go2rtc UDP port --- docker/main/rootfs/usr/local/go2rtc/create_config.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/docker/main/rootfs/usr/local/go2rtc/create_config.py b/docker/main/rootfs/usr/local/go2rtc/create_config.py index a7ffaf2da..7be440842 100644 --- a/docker/main/rootfs/usr/local/go2rtc/create_config.py +++ b/docker/main/rootfs/usr/local/go2rtc/create_config.py @@ -58,7 +58,15 @@ if go2rtc_config.get("log") is None: elif go2rtc_config["log"].get("format") is None: go2rtc_config["log"]["format"] = "text" +# ensure there is a default webrtc config if not go2rtc_config.get("webrtc", {}).get("candidates", []): + go2rtc_config["webrtc"] = {} + +# go2rtc should listen on 5000 tcp & udp by default +if not go2rtc_config["webrtc"].get("listen"): + go2rtc_config["webrtc"]["listen"] = ":5000" + +if not go2rtc_config["webrtc"].get("candidates", []): default_candidates = [] # use internal candidate if it was discovered when running through the add-on internal_candidate = os.environ.get(