summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2010-06-02 15:48:35 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2010-06-02 15:48:35 +0000
commit536ee480261049417d971463ad8d8b1c57fb7d79 (patch)
treee00c508712c172903d07e350f668407fdb9046ce
parent3edf3ebc166fa254cff28b42b8ceee936b8fd85f (diff)
downloadaports-536ee480261049417d971463ad8d8b1c57fb7d79.tar.bz2
aports-536ee480261049417d971463ad8d8b1c57fb7d79.tar.xz
testing/trac: added missing initd and confd from gentoo
-rw-r--r--testing/trac/APKBUILD12
-rw-r--r--testing/trac/tracd.confd13
-rwxr-xr-xtesting/trac/tracd.initd27
3 files changed, 46 insertions, 6 deletions
diff --git a/testing/trac/APKBUILD b/testing/trac/APKBUILD
index dd4a1f50d..419fb6e2d 100644
--- a/testing/trac/APKBUILD
+++ b/testing/trac/APKBUILD
@@ -11,8 +11,8 @@ depends="python py-setuptools py-genshi py-sqlite"
makedepends="python-dev"
install=
source="ftp://ftp.edgewall.com/pub/$pkgname/$_realname-$pkgver.tar.gz
- trac.confd
- trac.initd"
+ tracd.confd
+ tracd.initd"
_builddir="$srcdir"/$_realname-$pkgver
@@ -24,10 +24,10 @@ build() {
package() {
cd "$_builddir"
- install -m755 -D "$srcdir"/$pkgname.initd "$pkgdir"/etc/init.d/${pkgname}d
- install -m644 -D "$srcdir"/$pkgname.confd "$pkgdir"/etc/conf.d/${pkgname}d
+ install -m755 -D "$srcdir"/tracd.initd "$pkgdir"/etc/init.d/tracd
+ install -m644 -D "$srcdir"/tracd.confd "$pkgdir"/etc/conf.d/tracd
}
md5sums="3cd96dad0e4f25d977c422fd6e985e99 Trac-0.11.7.tar.gz
-70609adb7403e7badae33f9f4fdc4bf3 trac.confd
-66b91da45fbc5ab25ec2e0e7356020e2 trac.initd"
+95b1311ca65e1ffcd51a191542f45ba4 tracd.confd
+e53761b1e84c5d68c8e6c4b837e57008 tracd.initd"
diff --git a/testing/trac/tracd.confd b/testing/trac/tracd.confd
new file mode 100644
index 000000000..2cb9d292a
--- /dev/null
+++ b/testing/trac/tracd.confd
@@ -0,0 +1,13 @@
+# The commented variables in this file are the defaults that are used
+# in the init-script. You don't need to uncomment them except to
+# customize them to different values.
+
+# Port for tracd
+#TRACD_PORT="8000"
+
+# Options for tracd
+#TRACD_OPTS="--env-parent-dir /var/lib/trac/"
+
+# User and group as which to run tracd
+#TRACD_USER="tracd"
+#TRACD_GROUP="tracd"
diff --git a/testing/trac/tracd.initd b/testing/trac/tracd.initd
new file mode 100755
index 000000000..83f84052d
--- /dev/null
+++ b/testing/trac/tracd.initd
@@ -0,0 +1,27 @@
+#!/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.4 2010/05/28 14:43:40 arfrever 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 \
+ --env PYTHON_EGG_CACHE="/var/lib/trac/egg-cache" \
+ --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 $?
+}