[Pkg-voip-commits] [resiprocate] 01/01: Adapt init scripts to use log_daemon_msg

Daniel Pocock pocock at moszumanska.debian.org
Wed Jan 22 10:33:49 UTC 2014


This is an automated email from the git hooks/post-receive script.

pocock pushed a commit to branch master
in repository resiprocate.

commit 2429d2096e61512665d7e352147ad46805f3ed5a
Author: Daniel Pocock <daniel at pocock.com.au>
Date:   Wed Jan 22 11:31:19 2014 +0100

    Adapt init scripts to use log_daemon_msg
---
 debian/repro.init                   | 10 ++++------
 debian/resiprocate-turn-server.init | 10 ++++------
 2 files changed, 8 insertions(+), 12 deletions(-)

diff --git a/debian/repro.init b/debian/repro.init
index 41ff7c6..276c08f 100644
--- a/debian/repro.init
+++ b/debian/repro.init
@@ -42,14 +42,12 @@ set -e
 
 case "$1" in
   start)
-	echo -n "Starting $DESC: "
+	log_daemon_msg "Starting $DESC ($NAME)" $BIN
 	start-stop-daemon --start --quiet --pidfile $PIDFILE --exec $DAEMON -- $DAEMON_OPTS 
-	echo "$NAME."
 	;;
   stop)
-	echo -n "Stopping $DESC: "
+	log_daemon_msg "Stopping $DESC ($NAME)" $BIN
 	start-stop-daemon --stop --quiet --oknodo --user $USER --pidfile $PIDFILE --retry=${KILL_SPEC} --exec $DAEMON
-	echo "$NAME."
 	;;
   status)
 	echo -n "Status $DESC: "
@@ -66,17 +64,17 @@ case "$1" in
 	fi
 	;;
   reload|force-reload)
+	log_daemon_msg "Reloading $DESC ($NAME)" $BIN
 	if [ -f "$PIDFILE" ] ; then
 		start-stop-daemon --stop --signal HUP --quiet --pidfile $PIDFILE || rc=$?
 	fi
 	;;
   restart)
-	echo -n "Restarting $DESC: "
+	log_daemon_msg "Restarting $DESC ($NAME)" $BIN
 	#start-stop-daemon --stop --quiet --oknodo --pidfile $PIDFILE --exec $DAEMON
 	$0 stop
 	#start-stop-daemon --start --quiet --pidfile $PIDFILE --exec $DAEMON -- $DAEMON_OPTS
 	$0 start
-	echo "$NAME."
 	;;
   *)
 	N=/etc/init.d/$NAME
diff --git a/debian/resiprocate-turn-server.init b/debian/resiprocate-turn-server.init
index 904a0e6..16ded2e 100644
--- a/debian/resiprocate-turn-server.init
+++ b/debian/resiprocate-turn-server.init
@@ -40,14 +40,12 @@ set -e
 
 case "$1" in
   start)
-	echo -n "Starting $DESC: "
+	log_daemon_msg "Starting $DESC ($NAME)" $BIN
 	start-stop-daemon --start --quiet --pidfile $PIDFILE --exec $DAEMON -- $DAEMON_OPTS
-	echo "$NAME."
 	;;
   stop)
-	echo -n "Stopping $DESC: "
+	log_daemon_msg "Stopping $DESC ($NAME)" $BIN
 	start-stop-daemon --stop --quiet --oknodo --user $USER --pidfile $PIDFILE --exec $DAEMON
-	echo "$NAME."
 	;;
   status)
 	echo -n "Status $DESC: "
@@ -64,16 +62,16 @@ case "$1" in
 	fi
 	;;
   reload|force-reload)
+	log_daemon_msg "Reloading $DESC ($NAME)" $BIN
 	if [ -f "$PIDFILE" ] ; then
 		start-stop-daemon --stop --signal HUP --quiet --pidfile $PIDFILE || rc=$?
 	fi
 	;;
   restart)
-	echo -n "Restarting $DESC: "
+	log_daemon_msg "Restarting $DESC ($NAME)" $BIN
 	start-stop-daemon --stop --quiet --oknodo --pidfile $PIDFILE --exec $DAEMON
 	sleep 1
 	start-stop-daemon --start --quiet --pidfile $PIDFILE --exec $DAEMON -- $DAEMON_OPTS
-	echo "$NAME."
 	;;
   *)
 	N=/etc/init.d/$NAME

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-voip/resiprocate.git



More information about the Pkg-voip-commits mailing list