summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNathan Phillip Brink <binki@gentoo.org>2011-07-20 02:24:21 +0000
committerNathan Phillip Brink <binki@gentoo.org>2011-07-20 02:24:21 +0000
commita7234809ff42b5f17b1b5143de43b28d8df2ebf0 (patch)
tree4995987f36af4013cacefdae015a4f4360ec9795 /net-irc/atheme-services/files
parentImport from sci overlay, rename and rewrite; thanks to Martin Mokrejs <mmokre... (diff)
downloadgentoo-2-a7234809ff42b5f17b1b5143de43b28d8df2ebf0.tar.gz
gentoo-2-a7234809ff42b5f17b1b5143de43b28d8df2ebf0.tar.bz2
gentoo-2-a7234809ff42b5f17b1b5143de43b28d8df2ebf0.zip
Fix initial permissions of /var/run/atheme and remove bad prefix-support logic from init script. Reported by the_mgt/ich.
(Portage version: 2.2.0_alpha41-r1/cvs/Linux x86_64)
Diffstat (limited to 'net-irc/atheme-services/files')
-rw-r--r--net-irc/atheme-services/files/atheme-services.initd37
-rw-r--r--net-irc/atheme-services/files/atheme-services.initd.in45
2 files changed, 37 insertions, 45 deletions
diff --git a/net-irc/atheme-services/files/atheme-services.initd b/net-irc/atheme-services/files/atheme-services.initd
new file mode 100644
index 000000000000..7d643533ef1a
--- /dev/null
+++ b/net-irc/atheme-services/files/atheme-services.initd
@@ -0,0 +1,37 @@
+#!/sbin/runscript
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-irc/atheme-services/files/atheme-services.initd,v 1.1 2011/07/20 02:24:17 binki Exp $
+
+opts="reload"
+
+depend() {
+ need net
+ use ircd
+ provide irc-services
+}
+
+start() {
+ ATHEME_SERVICES_RUNDIR=/var/run/atheme
+ if ! [ -d "${ATHEME_SERVICES_RUNDIR}" ]; then
+ ebegin "Creating \`${ATHEME_SERVICES_RUNDIR}'"
+ install -o atheme-services -d "${ATHEME_SERVICES_RUNDIR}"
+ eend $?
+ fi
+
+ ebegin "Starting ${SVCNAME}"
+ start-stop-daemon --start --chuid atheme-services --exec /usr/bin/atheme-services
+ eend $?
+}
+
+reload() {
+ ebegin "Reloading ${SVCNAME}"
+ start-stop-daemon --signal HUP --pidfile /var/run/atheme/atheme.pid
+ eend $?
+}
+
+stop() {
+ ebegin "Stopping ${SVCNAME}"
+ start-stop-daemon --stop --quiet --pidfile /var/run/atheme/atheme.pid
+ eend $?
+}
diff --git a/net-irc/atheme-services/files/atheme-services.initd.in b/net-irc/atheme-services/files/atheme-services.initd.in
deleted file mode 100644
index b4ab6dba1f04..000000000000
--- a/net-irc/atheme-services/files/atheme-services.initd.in
+++ /dev/null
@@ -1,45 +0,0 @@
-#!/sbin/runscript
-# Copyright 1999-2011 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-irc/atheme-services/files/atheme-services.initd.in,v 1.1 2011/06/09 04:38:07 binki Exp $
-
-opts="reload"
-
-depend() {
- need net
- use ircd
- provide irc-services
-}
-
-start() {
- ATHEME_SERVICES_RUNDIR="@GENTOO_PORTAGE_EPREFIX@"/var/run/atheme
- if ! [ -d "${ATHEME_SERVICES_RUNDIR}" ]; then
- ebegin "Creating \`${ATHEME_SERVICES_RUNDIR}'"
-
- ATHEME_INSTALL_O="-o atheme-services"
- [ "@GENTOO_PORTAGE_EPREFIX@" ] && ATHEME_INSTALL_O=
-
- install ${ATHEME_INSTALL_O} -d "${ATHEME_SERVICES_RUNDIR}"
- eend $?
- fi
-
- ebegin "Starting ${SVCNAME}"
-
- ATHEME_SSD_CHUID="--chuid atheme-services"
- [ "@GENTOO_PORTAGE_EPREFIX@" ] && ATHEME_SSD_CHUID=
-
- start-stop-daemon --start ${ATHEME_SSD_CHUID} --exec "@GENTOO_PORTAGE_EPREFIX@"/usr/bin/atheme-services
- eend $?
-}
-
-reload() {
- ebegin "Reloading ${SVCNAME}"
- start-stop-daemon --signal HUP --pidfile "@GENTOO_PORTAGE_EPREFIX@"/var/run/atheme/atheme.pid
- eend $?
-}
-
-stop() {
- ebegin "Stopping ${SVCNAME}"
- start-stop-daemon --stop --quiet --pidfile "@GENTOO_PORTAGE_EPREFIX@"/var/run/atheme/atheme.pid
- eend $?
-}