Index: trunk/packages/sipb-xen-database/debian/changelog
===================================================================
--- trunk/packages/sipb-xen-database/debian/changelog	(revision 1215)
+++ trunk/packages/sipb-xen-database/debian/changelog	(revision 1216)
@@ -1,2 +1,8 @@
+sipb-xen-database (10.35) unstable; urgency=low
+
+  * Shorten initscript with spiffy new library from sipb-xen-base
+
+ -- Greg Price <price@mit.edu>  Fri, 24 Oct 2008 07:25:56 -0400
+
 sipb-xen-database (10.34) unstable; urgency=low
 
Index: trunk/packages/sipb-xen-database/debian/control
===================================================================
--- trunk/packages/sipb-xen-database/debian/control	(revision 1215)
+++ trunk/packages/sipb-xen-database/debian/control	(revision 1216)
@@ -15,5 +15,5 @@
 Package: sipb-xen-database-server
 Architecture: all
-Depends: ${misc:Depends}, ${python:Depends}, postgresql-8.3, python-sqlalchemy, python-psycopg2, sipb-xen-database-common, adduser
+Depends: ${misc:Depends}, ${python:Depends}, postgresql-8.3, python-sqlalchemy, python-psycopg2, sipb-xen-database-common, adduser, sipb-xen-base
 Description: Installs the SIPB Xen database server
  This tracks all the user VMs and is accessed from the VM host
Index: trunk/packages/sipb-xen-database/debian/sipb-xen-database-server.init
===================================================================
--- trunk/packages/sipb-xen-database/debian/sipb-xen-database-server.init	(revision 1215)
+++ trunk/packages/sipb-xen-database/debian/sipb-xen-database-server.init	(revision 1216)
@@ -11,29 +11,9 @@
 
 PACKAGE=sipb-xen-database-server
+PARENTPACKAGE=postgresql-8.3
+GEN_FILES=/etc/postgresql/8.3/main/pg_hba.conf
 
-# Exit if the package is not installed
-[ -x "/usr/bin/sipb-xen-database-tables" ] || exit 0
+dpkg -s "$PACKAGE" >/dev/null 2>/dev/null || exit 0
 
-. /lib/init/vars.sh
-. /lib/lsb/init-functions
-
-gen_config()
-{
-  for i in /etc/postgresql/8.3/main/pg_hba.conf
-  do mako-render $i.mako > $i
-  done
-}
-
-case "$1" in
-  start|reload|force-reload|restart)
-    log_begin_msg "Reloading config for $PACKAGE"
-    gen_config
-    log_end_msg $?
-    /etc/init.d/postgresql-8.3 "$1"
-    ;;
-  stop)
-    ;;
-  *)
-    log_success_msg "Usage: /etc/init.d/$PACKAGE {start|reload|force-reload|restart|stop}"
-    ;;
-esac
+. /lib/init/config-init.sh
+config_init "$1"
