Install systemd service in install script, skip empty audio device

Stop systemd service with SIGINT
This commit is contained in:
dec05eba
2023-10-15 18:11:47 +02:00
parent 3ae89c8d7c
commit bae4504370
6 changed files with 18 additions and 6 deletions

View File

@@ -14,6 +14,7 @@ Environment=REPLAYDURATION=60
Environment=OUTPUTDIR=%h/Videos
Environment=MAKEFOLDERS=no
ExecStart=/bin/sh -c 'AUDIO="${AUDIO_DEVICE:-$(pactl get-default-sink).monitor}"; gpu-screen-recorder -v no -w $WINDOW -c $CONTAINER -q $QUALITY -k $CODEC -ac $AUDIO_CODEC -a "$AUDIO" -f $FRAMERATE -r $REPLAYDURATION -o "$OUTPUTDIR" -mk $MAKEFOLDERS $ADDITIONAL_ARGS'
KillSignal=SIGINT
Restart=on-failure
RestartSec=5s