Permalink
Browse files

restart server only once if both interchange and interchange-ui

are installed
  • Loading branch information...
1 parent 3485ca0 commit ef1be7f738f13564a79ce7ec419db2a76714e52b @racke racke committed Aug 13, 2001
Showing with 42 additions and 5 deletions.
  1. +3 −1 debian/changelog
  2. +20 −1 debian/interchange-ui.postinst
  3. +1 −1 debian/interchange-ui.preinst
  4. +17 −1 debian/interchange.postinst
  5. +1 −1 debian/interchange.preinst
View
@@ -21,8 +21,10 @@ interchange (4.8.1-1) unstable; urgency=low
* Standards-Version updated
* dependencies to debconf added to interchange-ui and
interchange-cat-foundation to keep lintian happy
+ * restart server only once if both interchange and interchange-ui
+ are installed
- -- Stefan Hornburg (Racke) <racke@linuxia.de> Sun, 12 Aug 2001 23:20:58 +0200
+ -- Stefan Hornburg (Racke) <racke@linuxia.de> Mon, 13 Aug 2001 11:38:01 +0200
interchange (4.6.5-1) unstable; urgency=high
@@ -26,7 +26,26 @@ UI_LOCALE=$RET
#DEBHELPER#
-/etc/init.d/interchange restart
+# Check if we run the startup
+if [ -f /var/run/interchange-install ]; then
+ PACKAGES=""
+ exec 4</var/run/interchange-install
+ while read <&4 PKG; do
+ if [ ! "$PKG" = "interchange-ui" ]; then
+ PACKAGES="$PKG $PACKAGES"
+ fi
+ done
+ if [ -z "$PACKAGES" ]; then
+ rm /var/run/interchange-install
+ else
+ exec 5>/var/run/interchange-install
+ for PKG in $PACKAGES; do
+ echo "$PKG" >&5
+ done
+ fi
+fi
+
+/etc/init.d/interchange start
# Don't wait on Interchange to close file handles
db_stop
@@ -21,7 +21,7 @@
# the installed interchange packages, so only one server
# restart is needed
-echo interchange-ui > /var/run/interchange-install
+echo interchange-ui >> /var/run/interchange-install
#DEBHELPER#
@@ -88,7 +88,23 @@ fi
chown -R $USER.$GROUP /etc/interchange
# Check if we delay the startup
-rm /var/run/interchange-install
+if [ -f /var/run/interchange-install ]; then
+ PACKAGES=""
+ exec 4</var/run/interchange-install
+ while read <&4 PKG; do
+ if [ ! "$PKG" = "interchange" ]; then
+ PACKAGES="$PKG $PACKAGES"
+ fi
+ done
+ if [ -z "$PACKAGES" ]; then
+ rm /var/run/interchange-install
+ else
+ exec 5>/var/run/interchange-install
+ for PKG in $PACKAGES; do
+ echo "$PKG" >&5
+ done
+ fi
+fi
#DEBHELPER#
@@ -28,7 +28,7 @@ fi
# the installed interchange packages, so only one server
# restart is needed
-echo interchange > /var/run/interchange-install
+echo interchange >> /var/run/interchange-install
#DEBHELPER#

0 comments on commit ef1be7f

Please sign in to comment.