[apt-proxy-devel] r717 - trunk/debian

Xavier Lüthi xluthi at alioth.debian.org
Tue Dec 15 14:58:59 UTC 2009


Author: xluthi
Date: Tue Dec 15 14:58:59 2009
New Revision: 717

Log:
debian/init.d: Prevent apt-proxy to fail silently during startup (Closes: #432221)

Modified:
   trunk/debian/init.d

Modified: trunk/debian/init.d
==============================================================================
--- trunk/debian/init.d	Mon Dec 14 10:53:07 2009	(r716)
+++ trunk/debian/init.d	Tue Dec 15 14:58:59 2009	(r717)
@@ -14,6 +14,7 @@
 pidfile=$rundir/apt-proxy.pid 
 logfile=/var/log/apt-proxy.log
 application=/usr/sbin/apt-proxy
+process=$(basename $application)
 twistd=/usr/bin/twistd
 user=aptproxy
 group=nogroup
@@ -53,6 +54,10 @@
 	start-stop-daemon --start --quiet --exec $twistd -- \
             --pidfile=$pidfile 	--rundir=$rundir --python=$application \
 	    --logfile=$logfile 	--no_save
+        # check if process is actually running
+        sleep 1 # for some startup time and then check
+        ps  -U "$user" -o cmd | grep -q "^$process"
+
 	log_end_msg $?
     ;;
 



More information about the apt-proxy-devel mailing list