Commit 14989d0b authored by Yann E. MORIN's avatar Yann E. MORIN Committed by Peter Korsgaard
Browse files

package/tvheadend: new package

parent 6904b0ea
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -683,6 +683,7 @@ source "package/tinyhttpd/Config.in"
source "package/tn5250/Config.in"
source "package/transmission/Config.in"
source "package/ttcp/Config.in"
source "package/tvheadend/Config.in"
source "package/udpcast/Config.in"
source "package/ulogd/Config.in"
source "package/ushare/Config.in"
+19 −0
Original line number Diff line number Diff line
comment "tvheadend requires a toolchain with LARGEFILE support"
    depends on !BR2_LARGEFILE

config BR2_PACKAGE_TVHEADEND
	bool "tvheadend"
	depends on BR2_LARGEFILE
	select BR2_PACKAGE_OPENSSL
	help
	  Tvheadend is a TV streaming server for Linux supporting DVB-S,
	  DVB-S2, DVB-C, DVB-T, ATSC, IPTV, and Analog video (V4L) as
	  input sources.
	  
	  https://www.lonelycoder.com/redmine/projects/tvheadend/
	  
	  Note:
	    - a default user has been created to log in the web configuration
	      GUI: admin/admin; you can change it at your discretion at runtime.
	    - if you want Avahi support, you'll need to enable:
	          Avahi, D-Bus, libdaemon
+54 −0
Original line number Diff line number Diff line
#! /bin/sh
# tvheadend startup script inspired by the Debian one in the package

# Author: Yann E. MORIN <yann.morin.1998@free.fr>

PATH=/usr/sbin:/usr/bin:/sbin:/bin
NAME=tvheadend
DAEMON=/usr/bin/$NAME
PIDFILE=/var/run/$NAME.pid

[ -f "${DAEMON}" -a -x "${DAEMON}" ] || exit 0

# Read configuration variable file if it is present
[ -r "/etc/default/${NAME}" ] && . "/etc/default/${NAME}"

ARGS="-f"
[ -z "${TVH_USER}"      ] || ARGS="${ARGS} -u ${TVH_USER}"
[ -z "${TVH_GROUP}"     ] || ARGS="${ARGS} -g ${TVH_GROUP}"
[ -z "${TVH_ADAPTERS}"  ] || ARGS="${ARGS} -a ${TVH_ADAPTERS}"
[ -z "${TVH_HTTP_PORT}" ] || ARGS="${ARGS} -w ${TVH_HTTP_PORT}"
[ -z "${TVH_HTSP_PORT}" ] || ARGS="${ARGS} -e ${TVH_HTSP_PORT}"
[ "${TVH_DEBUG}" = "1"  ] && ARGS="${ARGS} -s"

case "$1" in
    start)
        printf "Starting TVHeadend daemon: "
        if start-stop-daemon -S -q -p ${PIDFILE} -m --exec "${DAEMON}" -- ${ARGS}; then
            printf "OK\n"
        else
            printf "failed\n"
        fi
        ;;
    stop)
        printf "Stoping TVHeadend daemon: "
        start-stop-daemon -K -q -p ${PIDFILE} -s TERM
        sleep 2
        if start-stop-daemon -K -q -p ${PIDFILE} -t; then
            printf "failed, killing: "
            start-stop-daemon -K -q -p ${PIDFILE} -s KILL -o
        fi
        printf "OK\n"
        ;;
    restart|force-reload)
        "${0}" stop
        sleep 2
        "${0}" stop
        ;;
    *)
        echo "Usage: $SCRIPTNAME {start|stop|restart|force-reload}" >&2
        exit 1
        ;;
esac

:
+13 −0
Original line number Diff line number Diff line
{
        "enabled": 1,
        "username": "admin",
        "password": "admin",
        "comment": "TVHeadend admin user",
        "prefix": "0.0.0.0/0",
        "streaming": 1,
        "dvr": 1,
        "dvrallcfg": 1,
        "webui": 1,
        "admin": 1,
        "id": "1"
}
+7 −0
Original line number Diff line number Diff line
# Once we have a real user, we'll use it
TVH_USER=root
TVH_GROUP=root
#TVH_ADAPTERS=
#TVH_HTTP_PORT=9981
#TVH_HTSP_PORT=9982
#TVH_DEBUG=1
Loading