summaryrefslogtreecommitdiff
path: root/debian/echolot.init
diff options
context:
space:
mode:
authorPeter Palfrader <peter@palfrader.org>2002-11-12 01:07:05 +0000
committerPeter Palfrader <peter@palfrader.org>2002-11-12 01:07:05 +0000
commita5a75de615b8e131c4be7f3f12c2b293fa997ae3 (patch)
tree2f563fce83ce5867ceb754da6028ac768f4e2249 /debian/echolot.init
parent99759fe3d2276a250881acbe5390ca00409dd346 (diff)
Have Echolot disabled by default in /etc/default/echolot.
Add some more comments to README.Debian. Also process pending commands upon pingd startup.
Diffstat (limited to 'debian/echolot.init')
-rwxr-xr-xdebian/echolot.init24
1 files changed, 16 insertions, 8 deletions
diff --git a/debian/echolot.init b/debian/echolot.init
index 3ee6d0b..5276149 100755
--- a/debian/echolot.init
+++ b/debian/echolot.init
@@ -20,6 +20,10 @@ DESC="Echolot Ping Daemon"
NAME="pingd"
test -f $DAEMON || exit 0
+# Reads config file (will override defaults above)
+[ -r /etc/default/echolot ] && . /etc/default/echolot
+
+
wait_for_deaddaemon () {
PID=$1
sleep 3
@@ -97,14 +101,18 @@ start)
echo "$PIDFILE."
fi
fi
- echo -n "Starting $DESC: "
- start-stop-daemon \
- --start \
- --quiet \
- --pidfile $PIDFILE \
- --chuid $USER:$GROUP \
- --exec $DAEMON -- --detach $VERBOSE --quiet start
- echo "$NAME."
+ if [ $RUN_ECHOLOT -gt 0 ]; then
+ echo -n "Starting $DESC: "
+ start-stop-daemon \
+ --start \
+ --quiet \
+ --pidfile $PIDFILE \
+ --chuid $USER:$GROUP \
+ --exec $DAEMON -- --detach $VERBOSE --process --quiet start
+ echo "$NAME."
+ else
+ echo "Not starting $DESC: disabled in configuration"
+ fi
;;
stop)