aboutsummaryrefslogtreecommitdiffstats
path: root/testing/motion/motion.initd
diff options
context:
space:
mode:
Diffstat (limited to 'testing/motion/motion.initd')
-rw-r--r--testing/motion/motion.initd27
1 files changed, 27 insertions, 0 deletions
diff --git a/testing/motion/motion.initd b/testing/motion/motion.initd
new file mode 100644
index 0000000000..78493c3d44
--- /dev/null
+++ b/testing/motion/motion.initd
@@ -0,0 +1,27 @@
+#!/sbin/runscript
+# Copyright 1999-2004 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-misc/rsync/files/rsyncd.init.d,v 1.5 2007/02/23 11:33:59 uberlord Exp $
+
+description="motion daemon"
+user="motion"
+command="/usr/bin/motion"
+pidfile="/var/run/${RC_SVCNAME}/${RC_SVCNAME}.pid"
+
+start() {
+ ebegin "Starting ${RC_SVCNAME}"
+ start-stop-daemon --start \
+ --exec ${command} \
+ --user ${user} \
+ --pidfile ${pidfile} \
+ -- ${MOTION_OPTS}
+ eend $?
+}
+
+stop() {
+ ebegin "Stopping ${RC_SVCNAME}"
+ start-stop-daemon --stop \
+ --exec ${command} \
+ --pidfile ${pidfile}
+ eend $?
+}