Skip to content

Commit f877dcb

Browse files
committed
Use exec
1 parent 3853009 commit f877dcb

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

scripts/files/camera-streamer/camera-streamer-libcamera.service

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,10 @@ StartLimitBurst=10
77
[Service]
88
EnvironmentFile=/boot/camera-streamer/libcamera.conf
99
ExecCondition=/bin/sh -c "/usr/bin/libcamera-hello --list-cameras | grep -o '/base/soc/[^)]*'"
10-
ExecStart=/bin/sh -c "/usr/local/bin/camera-streamer \
10+
ExecStart=/bin/sh -c "exec /usr/local/bin/camera-streamer \
1111
-http-port=${PORT} \
1212
-camera-type=libcamera \
13-
-camera-path=$(/usr/bin/libcamera-hello --list-cameras | grep -o '/base/soc/[^)]*') \
13+
-camera-path=$(/usr/bin/libcamera-hello --list-cameras | grep -o '/base/soc/[^)]*' | head -n1) \
1414
-camera-format=YUYV \
1515
-camera-width=${WIDTH} -camera-height=${HEIGHT} \
1616
-camera-fps=${FRAMERATE} \

scripts/files/camera-streamer/camera-streamer-usb@.service

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ StartLimitBurst=10
99
[Service]
1010
EnvironmentFile=/boot/camera-streamer/%i.conf
1111
ExecCondition=/bin/sh -c "[ -e $DEVICE ]"
12-
ExecStart=/bin/sh -c "/usr/local/bin/camera-streamer \
12+
ExecStart=/bin/sh -c "exec /usr/local/bin/camera-streamer \
1313
-http-port=${PORT} \
1414
-camera-path="${DEVICE}" \
1515
-camera-type=v4l2 \

0 commit comments

Comments
 (0)