From 19c4803ff0fb882ad20510ef0b1860365ab7f26e Mon Sep 17 00:00:00 2001 From: Donny Davies Date: Sat, 26 Jan 2002 22:43:51 +0000 Subject: Tidied up the initscript: we install a config file, so remove the checkconfig() install a /etc/conf.d/metalog file Couple small cosmstic changes. --- app-admin/metalog/files/metalog.confd | 4 ++++ app-admin/metalog/files/metalog.rc6 | 29 +++++++++-------------------- 2 files changed, 13 insertions(+), 20 deletions(-) create mode 100644 app-admin/metalog/files/metalog.confd (limited to 'app-admin/metalog/files') diff --git a/app-admin/metalog/files/metalog.confd b/app-admin/metalog/files/metalog.confd new file mode 100644 index 000000000000..14b0fe61424e --- /dev/null +++ b/app-admin/metalog/files/metalog.confd @@ -0,0 +1,4 @@ +# Config file for /etc/init.d/metalog + +# Add '-s' if you dont want buffering. (See things realtime) +METALOG_OPTS="-B" diff --git a/app-admin/metalog/files/metalog.rc6 b/app-admin/metalog/files/metalog.rc6 index 9fa030dd6620..48fd89919f02 100644 --- a/app-admin/metalog/files/metalog.rc6 +++ b/app-admin/metalog/files/metalog.rc6 @@ -1,32 +1,21 @@ #!/sbin/runscript # Copyright 1999-2002 Gentoo Technologies, Inc. # Distributed under the terms of the GNU General Public License, v2 or later -# $Header: /var/cvsroot/gentoo-x86/app-admin/metalog/files/metalog.rc6,v 1.4 2002/01/26 15:22:56 aeoo Exp $ - -METALOG_PID="/var/run/metalog.pid" +# $Header: /var/cvsroot/gentoo-x86/app-admin/metalog/files/metalog.rc6,v 1.5 2002/01/26 22:43:51 woodchip Exp $ depend() { - need clock -} - -checkconfig() { - if [ ! -e /etc/metalog/metalog.conf ] ; then - eerror "You need an /etc/metalog/metalog.conf file to run metalog" - eerror "There is a sample config file in /usr/share/docs/metalog" - return 1 - fi + need clock } start() { - checkconfig || return 1 - ebegin "Starting metalog" - start-stop-daemon --start --quiet --exec /usr/sbin/metalog -- -B \ - -p ${METALOG_PID} - eend $? + ebegin "Starting metalog" + start-stop-daemon --start --quiet --exec /usr/sbin/metalog \ + -- -p /var/run/metalog.pid ${METALOG_OPTS} + eend $? } stop() { - ebegin "Stopping metalog" - start-stop-daemon --stop --quiet --pidfile ${METALOG_PID} - eend $? + ebegin "Stopping metalog" + start-stop-daemon --stop --quiet --pidfile /var/run/metalog.pid + eend $? } -- cgit v1.2.3-65-gdbad