Merge pull request #8658 from jose1711/mjpg_streamer-file_output

Make mjpg-streamer init script recognize file output plugin
This commit is contained in:
Rosen Penev 2019-04-30 11:59:44 -07:00 committed by GitHub
commit d31b23b343
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 24 additions and 1 deletions

View File

@ -7,7 +7,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=mjpg-streamer
PKG_VERSION:=2018-10-25
PKG_RELEASE:=1
PKG_RELEASE:=2
PKG_MAINTAINER:=Roger D <rogerdammit@gmail.com>, \
Ted Hess <thess@kitschensync.net>

View File

@ -80,6 +80,29 @@ start_instance() {
[ -n "$username" ] && [ -n "$password" ] && output_arg="${output_arg} --credentials $username:$password"
fi
if [ "x$output" = 'xfile' ]; then
output_arg="output_file.so"
config_get folder "$s" 'folder'
[ -n "$folder" ] && output_arg="${output_arg} --folder $folder"
config_get delay "$s" 'delay'
[ -n "$delay" ] && output_arg="${output_arg} --delay $delay"
config_get link "$s" 'link'
[ -n "$link" ] && output_arg="${output_arg} --link $link"
config_get ringbuffer "$s" 'ringbuffer'
[ -n "$ringbuffer" ] && output_arg="${output_arg} --size $ringbuffer"
config_get exceed "$s" 'exceed'
[ -n "$exceed" ] && output_arg="${output_arg} --exceed $exceed"
config_get command "$s" 'command'
[ -n "$command" ] && output_arg="${output_arg} --command $command"
fi
if [ -z "$output_arg" ]; then
error "unsuported output option '$output' in section '$s'"
return 1