Systemd replay service: record default audio output by default

This commit is contained in:
dec05eba 2023-07-28 21:51:09 +02:00
parent 0db86f4a69
commit 1cf7c77871

View File

@ -8,10 +8,11 @@ Environment=CONTAINER=mp4
Environment=QUALITY=very_high Environment=QUALITY=very_high
Environment=CODEC=auto Environment=CODEC=auto
Environment=AUDIO_CODEC=opus Environment=AUDIO_CODEC=opus
Environment=AUDIO_DEVICE=
Environment=FRAMERATE=60 Environment=FRAMERATE=60
Environment=REPLAYDURATION=60 Environment=REPLAYDURATION=60
Environment=OUTPUTDIR=%h/Videos Environment=OUTPUTDIR=%h/Videos
ExecStart=gpu-screen-recorder -v no -w $WINDOW -c $CONTAINER -q $QUALITY -k $CODEC -ac $AUDIO_CODEC -f $FRAMERATE -r $REPLAYDURATION -o $OUTPUTDIR $ADDITIONAL_ARGS 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" $ADDITIONAL_ARGS'
Restart=on-failure Restart=on-failure
RestartSec=5s RestartSec=5s