[Pkg-puppet-devel] [SCM] Puppet packaging for Debian branch, master, updated. puppet-0.24.5-rc3-1469-gc504d0f

Andrew Pollock apollock at debian.org
Wed Dec 16 19:33:38 UTC 2009


The following commit has been merged in the master branch:
commit c504d0f4078d220a5d1828fbfb0b73b8dc4b2198
Author: Andrew Pollock <apollock at debian.org>
Date:   Wed Dec 16 11:33:04 2009 -0800

    Adjust the location of the pid files for Debian bug #561231

diff --git a/debian/changelog b/debian/changelog
index c4fa217..077a89f 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,10 +1,15 @@
 puppet (0.25.1-3) unstable; urgency=low
 
+  [ Nigel Kersten ]
   * cherry pick upstream fix for puppetrun with tags (closes: #559092)
   * cherry pick upstream fix for supplementary groups not being reset.
     (CVE-2009-3564) (closes: #551073)
 
- -- Nigel Kersten <nigelk at google.com>  Wed, 16 Dec 2009 11:04:29 -0800
+  [ Andrew Pollock ]
+  * debian/{puppet,puppetmaster}.pid: Correct the path to the pidfiles 
+    (closes: #561231)
+
+ -- Andrew Pollock <apollock at debian.org>  Wed, 16 Dec 2009 11:23:31 -0800
 
 puppet (0.25.1-2) unstable; urgency=low
 
diff --git a/debian/puppet.init b/debian/puppet.init
index e244313..62b07b0 100644
--- a/debian/puppet.init
+++ b/debian/puppet.init
@@ -13,6 +13,7 @@ DAEMON=/usr/sbin/puppetd
 DAEMON_OPTS=""
 NAME=puppetd
 DESC="puppet configuration management tool"
+PIDFILE="/var/run/${NAME}.pid"
 
 test -x $DAEMON || exit 0
 
@@ -29,12 +30,12 @@ is_true() {
 }
 
 reload_puppet() {
-	start-stop-daemon --stop --quiet --signal HUP --pidfile /var/run/puppet/$NAME.pid
+	start-stop-daemon --stop --quiet --signal HUP --pidfile $PIDFILE 
 }
 
 start_puppet() {
     if is_true "$START" ; then
-	start-stop-daemon --start --quiet --pidfile /var/run/puppet/$NAME.pid \
+	start-stop-daemon --start --quiet --pidfile $PIDFILE \
 	    --startas $DAEMON -- $DAEMON_OPTS
     else
 	echo ""
@@ -43,16 +44,9 @@ start_puppet() {
 }
 
 stop_puppet() {
-	start-stop-daemon --stop --quiet --pidfile /var/run/puppet/$NAME.pid
+	start-stop-daemon --stop --quiet --pidfile $PIDFILE
 }
 
-if [ ! -d /var/run/puppet ]; then
-	rm -rf /var/run/puppet
-	mkdir -p /var/run/puppet
-fi
-
-chown puppet:puppet /var/run/puppet
-
 case "$1" in
     start)
 	log_begin_msg "Starting $DESC"
diff --git a/debian/puppetmaster.init b/debian/puppetmaster.init
index a971525..f4fd47c 100644
--- a/debian/puppetmaster.init
+++ b/debian/puppetmaster.init
@@ -41,13 +41,13 @@ start_puppetmaster() {
 	    NUMSTART=0
 	    STARTPORT=$PORT
 	    while [ $NUMSTART -lt $PUPPETMASTERS ]; do 
-		start-stop-daemon --start --quiet --pidfile=/var/run/puppet/$NAME-$STARTPORT.pid \
-		    --startas $DAEMON -- $DAEMON_OPTS --masterport=$STARTPORT --pidfile=/var/run/puppet/$NAME-$STARTPORT.pid
+		start-stop-daemon --start --quiet --pidfile=/var/run/${NAME}-${STARTPORT}.pid \
+		    --startas $DAEMON -- $DAEMON_OPTS --masterport=$STARTPORT --pidfile=/var/run/${NAME}-${STARTPORT}.pid
 		STARTPORT=$(($STARTPORT + 1))
 		NUMSTART=$(($NUMSTART + 1))
 	    done
 	else
-	    start-stop-daemon --start --quiet --pidfile /var/run/puppet/$NAME.pid \
+	    start-stop-daemon --start --quiet --pidfile /var/run/${NAME}.pid \
 		--startas $DAEMON -- $DAEMON_OPTS --masterport=$PORT
 	fi
     else
@@ -62,13 +62,13 @@ stop_puppetmaster() {
 	NUMSTART=0
 	STOPPORT=$PORT
 	while [ $NUMSTART -lt $PUPPETMASTERS ]; do 
-	    start-stop-daemon --stop --quiet --pidfile /var/run/puppet/$NAME-$STOPPORT.pid
-	    rm /var/run/puppet/$NAME-$STOPPORT.pid
+	    start-stop-daemon --stop --quiet --pidfile /var/run/${NAME}-${STOPPORT}.pid
+	    rm /var/run/${NAME}-${STOPPORT}.pid
 	    STOPPORT=$(($STOPPORT + 1))
 	    NUMSTART=$(($NUMSTART + 1))
 	done
     else
-	start-stop-daemon --stop --quiet --pidfile /var/run/puppet/$NAME.pid
+	start-stop-daemon --stop --quiet --pidfile /var/run/${NAME}.pid
     fi
 }
 

-- 
Puppet packaging for Debian



More information about the Pkg-puppet-devel mailing list