Rework style

This commit is contained in:
Nick Mowen 2023-01-15 17:40:21 -07:00
parent 218c571459
commit cc65442d24
2 changed files with 4 additions and 4 deletions

View File

@ -4,7 +4,8 @@
set -o errexit -o nounset -o pipefail
raw_config = python3 /usr/local/go2rtc/create_config.py
# Replace the bash process with the go2rtc process, redirecting stderr to stdout
exec 2>&1
exec python3 /usr/local/go2rtc/create_config.py
exec go2rtc
exec go2rtc -config="${raw_config}"

View File

@ -27,5 +27,4 @@ if not go2rtc_config.get("log", {}).get("format"):
if not go2rtc_config.get("webrtc", {}).get("candidates", []):
go2rtc_config["webrtc"] = {"candidates": ["stun:8555"]}
with open('/usr/local/go2rtc/bin/config.yaml', 'w') as yaml_file:
yaml.dump(go2rtc_config, yaml_file)
print(yaml.dump(go2rtc_config, default_flow_style=False))