summaryrefslogtreecommitdiff
path: root/www-apps/trac/files/tracd.initd
diff options
context:
space:
mode:
authorGluzskiy Alexandr <sss123next@list.ru>2010-03-26 15:00:27 +0200
committerGluzskiy Alexandr <sss123next@list.ru>2010-03-26 15:00:27 +0200
commitd379fedd1e998a5b92213adf89ec5f2376ab7198 (patch)
treeb8a179ea3041681b19359035f160edf252391029 /www-apps/trac/files/tracd.initd
parent8234ae2bfefc148dddbcb5180aab8fec632a6d2d (diff)
deleted: www-apps/trac/files
new file: www-apps/trac/files/9138-mysql-key-size-r9405.patch new file: www-apps/trac/files/postinst-en.txt new file: www-apps/trac/files/postupgrade-en.txt new file: www-apps/trac/files/tracd.confd new file: www-apps/trac/files/tracd.initd new file: www-apps/trac/files/tracd.initd.2 modified: www-apps/trac/trac-9999.ebuild
Diffstat (limited to 'www-apps/trac/files/tracd.initd')
-rwxr-xr-xwww-apps/trac/files/tracd.initd26
1 files changed, 26 insertions, 0 deletions
diff --git a/www-apps/trac/files/tracd.initd b/www-apps/trac/files/tracd.initd
new file mode 100755
index 0000000..c63b794
--- /dev/null
+++ b/www-apps/trac/files/tracd.initd
@@ -0,0 +1,26 @@
+#!/sbin/runscript
+# Copyright 1999-2006 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License, v2 or later
+# $Header: /var/cvsroot/gentoo-x86/www-apps/trac/files/tracd.initd,v 1.3 2008/07/16 21:20:07 pva Exp $
+
+depend() {
+ need net
+}
+
+start() {
+ ebegin "Starting tracd"
+ # tracd fails to create pidfile if started as non-root user, thus we are asking
+ # s-s-d to do that. To have correct pid we avoid -d option of tracd and use
+ # --background option of s-s-d.
+ start-stop-daemon --start --chuid ${TRACD_USER:-tracd}:${TRACD_GROUP:-tracd} \
+ --pidfile /var/run/tracd.pid --make-pidfile --background \
+ --exec /usr/bin/python -- /usr/bin/tracd \
+ -p ${TRACD_PORT:-8000} ${TRACD_OPTS:---env-parent-dir /var/lib/trac/}
+ eend $?
+}
+
+stop() {
+ ebegin "Stopping tracd"
+ start-stop-daemon --stop --quiet --pidfile /var/run/tracd.pid
+ eend $?
+}