[25860] in Source-Commits

home help back first fref pref prev next nref lref last post

/svn/athena r25268 - trunk/debathena/config/cluster-cups-config/debian

daemon@ATHENA.MIT.EDU (Jonathan D Reed)
Wed Jul 20 17:50:53 2011

Date: Wed, 20 Jul 2011 17:50:47 -0400
From: Jonathan D Reed <jdreed@MIT.EDU>
Message-Id: <201107202150.p6KLol3i012155@drugstore.mit.edu>
To: source-commits@mit.edu
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Author: jdreed
Date: 2011-07-20 17:50:47 -0400 (Wed, 20 Jul 2011)
New Revision: 25268

Modified:
   trunk/debathena/config/cluster-cups-config/debian/configure-athena-printers
   trunk/debathena/config/cluster-cups-config/debian/debathena-cluster-cups-config.init
Log:
Create a flag file while we're adding the printers at boot time

Modified: trunk/debathena/config/cluster-cups-config/debian/configure-athena-printers
===================================================================
--- trunk/debathena/config/cluster-cups-config/debian/configure-athena-printers	2011-07-20 20:44:05 UTC (rev 25267)
+++ trunk/debathena/config/cluster-cups-config/debian/configure-athena-printers	2011-07-20 21:50:47 UTC (rev 25268)
@@ -57,6 +57,10 @@
 	    exit 1
 	fi
     fi
+    if [ "$(lpstat -r)" != "scheduler is running" ]; then
+      echo "FATAL: cups claimed to have started, but lpstat -r says it's not running!"
+      exit 1
+    fi
 }
 
 case "$1" in

Modified: trunk/debathena/config/cluster-cups-config/debian/debathena-cluster-cups-config.init
===================================================================
--- trunk/debathena/config/cluster-cups-config/debian/debathena-cluster-cups-config.init	2011-07-20 20:44:05 UTC (rev 25267)
+++ trunk/debathena/config/cluster-cups-config/debian/debathena-cluster-cups-config.init	2011-07-20 21:50:47 UTC (rev 25268)
@@ -17,12 +17,14 @@
   start)
     if [ -f /var/lib/debathena-cluster-cups-config-reconfigure_required ]; then
       log_action_msg "Adding cluster printers"
+      touch /var/run/debathena-adding-printers
       if /usr/share/debathena-cluster-cups-config/configure-athena-printers add; then
 	rm -f /var/lib/debathena-cluster-cups-config-reconfigure_required
 	log_end_msg 0
       else
 	log_end_msg 1
       fi
+      rm /var/run/debathena-adding-printers
     fi
     ;;
   stop|restart|reload|force-reload|status)


home help back first fref pref prev next nref lref last post