mediamtx: allow camera

This commit is contained in:
Motiejus Jakštys 2024-10-21 15:06:33 +03:00
parent 4e2ee9dd21
commit 5ffff18bb2

View File

@ -1,7 +1,8 @@
{ {
lib,
pkgs,
config, config,
myData, myData,
pkgs,
... ...
}: }:
let let
@ -79,6 +80,15 @@ in
services.mediamtx = { services.mediamtx = {
enable = true; enable = true;
allowVideoAccess = true;
settings = {
paths = {
cam = {
runOnInit = "${lib.getExe pkgs.ffmpeg} -f v4l2 -i /dev/video0 -f rtsp rtsp://localhost:$RTSP_PORT/$RTSP_PATH";
runOnInitRestart = true;
};
};
};
}; };
mj = { mj = {