summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'media-tv/pytivo-wmcbrine/files/pyTivo.initd.sh')
-rw-r--r--media-tv/pytivo-wmcbrine/files/pyTivo.initd.sh31
1 files changed, 31 insertions, 0 deletions
diff --git a/media-tv/pytivo-wmcbrine/files/pyTivo.initd.sh b/media-tv/pytivo-wmcbrine/files/pyTivo.initd.sh
new file mode 100644
index 000000000..00aa9e905
--- /dev/null
+++ b/media-tv/pytivo-wmcbrine/files/pyTivo.initd.sh
@@ -0,0 +1,31 @@
+#!/sbin/runscript
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+depend() {
+ need localmount net
+ after bootmisc
+}
+
+start() {
+ ebegin "Starting pyTivo"
+ start-stop-daemon --start --exec /usr/bin/pytivo \
+ --pidfile /var/run/pytivo.pid -m -N 19 -c pytivo:pytivo \
+ -- > /dev/null 2>&1 &
+ eend $?
+}
+
+stop() {
+ ebegin "Stopping pyTivo"
+ start-stop-daemon --stop --exec /usr/bin/pytivo \
+ --pidfile /var/run/pytivo.pid
+ eend $?
+}
+
+restart() {
+ stop
+ sleep 2
+ start
+}
+