From 6b26fc753ec5d63b5eb359c7cf5d6620308e0745 Mon Sep 17 00:00:00 2001 From: Blake Blackshear Date: Fri, 9 Jul 2021 20:22:11 -0500 Subject: [PATCH] include ffmpeg_cmds in config endpoint --- frigate/http.py | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/frigate/http.py b/frigate/http.py index 2f3a15221..55b04ce75 100644 --- a/frigate/http.py +++ b/frigate/http.py @@ -277,7 +277,16 @@ def events(): @bp.route("/config") def config(): - return jsonify(current_app.frigate_config.dict()) + config = current_app.frigate_config.dict() + + # add in the ffmpeg_cmds + for camera_name, camera in current_app.frigate_config.cameras.items(): + camera_dict = config["cameras"][camera_name] + camera_dict["ffmpeg_cmds"] = camera.ffmpeg_cmds + for cmd in camera_dict["ffmpeg_cmds"]: + cmd["cmd"] = " ".join(cmd["cmd"]) + + return jsonify(config) @bp.route("/config/schema")