diff options
Diffstat (limited to 'roles/streaming/mpv-headless/templates/ssh-forced.sh.j2')
-rw-r--r-- | roles/streaming/mpv-headless/templates/ssh-forced.sh.j2 | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/roles/streaming/mpv-headless/templates/ssh-forced.sh.j2 b/roles/streaming/mpv-headless/templates/ssh-forced.sh.j2 index 777f0b32..35e9571e 100644 --- a/roles/streaming/mpv-headless/templates/ssh-forced.sh.j2 +++ b/roles/streaming/mpv-headless/templates/ssh-forced.sh.j2 @@ -15,14 +15,14 @@ case "$command" in play) media_file="/srv/media/$(basename "$arg")" if [ -e "$media_file" ]; then - exec ./play "$media_file" + echo '{"command": ["loadfile", "'"$media_file"'"]}' | socat - /var/lib/player/ctl.sock else echo "file '$media_file' not found!" exit 1 fi ;; stop) - killall mpv + echo '{"command": ["playlist-remove", "current"]}' | socat - /var/lib/player/ctl.sock ;; *) echo "invalid command: '$command'" |