droidcam-with-octoprint/services/droidcam-streamer.service
2023-10-01 14:40:20 +02:00

15 lines
461 B
Desktop File

[Unit]
Description=DroidCam streaming
BindsTo=droidcam.service
StartLimitIntervalSec=0
[Service]
Type=simple
# this is cursed
ExecStart=/home/pi/go/bin/mjpeg-server -a ":8080" -b gaysex -- bash -c 'while [[ true ]]; do gst-launch-1.0 -v v4l2src device=/dev/video1 ! videoconvert ! video/x-raw,format=I420 ! v4l2jpegenc ! multipartmux boundary=gaysex ! filesink location=/dev/stdout || true; done'
Restart=always
RestartSec=5
[Install]
WantedBy=default.target