Mercurial > noffle
view debian/init @ 328:3841bbff35d5 noffle
[svn] added xinetd example configuration
author | godisch |
---|---|
date | Mon, 24 Feb 2003 06:26:30 +0000 |
parents | 399ccb5e641b |
children | 08222dbe6eb0 |
line wrap: on
line source
#!/bin/sh # $Id: init 437 2003-02-16 08:47:33Z godisch $ PATH=/bin:/usr/bin:/sbin:/usr/sbin NOFFLE=/usr/bin/noffle if [ -x /usr/sbin/pppd ]; then NOFFLE_FETCHMODE="ppp" else NOFFLE_FETCHMODE="cron" fi [ -f /etc/default/noffle ] && . /etc/default/noffle [ -x "$NOFFLE" ] || exit 0 case "$1" in online|offline) echo "Switching offline news server to $1 mode: noffle." $NOFFLE --$1 ;; start) echo "Initializing offline news server: noffle." [ "$NOFFLE_FETCHMODE" = ppp ] && $NOFFLE --offline [ "$NOFFLE_FETCHMODE" = cron ] && $NOFFLE --online ;; stop) $0 offline ;; restart|force-reload) $0 start ;; *) echo "Usage: $0 {start|stop}" >&2 exit 1 ;; esac exit 0