Don't include /var/run/shibboleth in the package and clean up on remove
authorRuss Allbery <rra@debian.org>
Fri, 21 Aug 2009 18:56:50 +0000 (11:56 -0700)
committerRuss Allbery <rra@debian.org>
Fri, 21 Aug 2009 18:57:46 +0000 (11:57 -0700)
- Don't ship /var/run/shibboleth in the package.
- Remove /var/run/shibboleth in postrm if it exists.

debian/changelog
debian/libapache2-mod-shib2.postrm [new file with mode: 0755]
debian/rules

index 41c70c3..ac23b51 100644 (file)
@@ -33,6 +33,8 @@ shibboleth-sp2 (2.2.1+dfsg-1) UNRELEASED; urgency=low
     TestShib web pages.
   * Update standards version to 3.8.3.
     - Create /var/run/shibboleth in the init script if it doesn't exist.
+    - Don't ship /var/run/shibboleth in the package.
+    - Remove /var/run/shibboleth in postrm if it exists.
 
  -- Russ Allbery <rra@debian.org>  Fri, 24 Jul 2009 15:29:01 -0700
 
diff --git a/debian/libapache2-mod-shib2.postrm b/debian/libapache2-mod-shib2.postrm
new file mode 100755 (executable)
index 0000000..d039399
--- /dev/null
@@ -0,0 +1,7 @@
+#!/bin/sh
+
+set -e
+
+if [ "$1" = purge ] || [ "$1" = remove ] ; then
+    rm -rf /var/run/shibboleth
+fi
index f9392e0..b1fb7a3 100755 (executable)
@@ -85,6 +85,7 @@ install-stamp:
        dh_clean -k
        $(MAKE) DESTDIR=$(CURDIR)/debian/tmp install
        rm -r $(CURDIR)/debian/tmp/usr/share/doc/shibboleth
+       rm -r $(CURDIR)/debian/tmp/var/run
        rm $(CURDIR)/debian/tmp/etc/shibboleth/*.dist
        rm $(CURDIR)/debian/tmp/etc/shibboleth/*.config
        rm $(CURDIR)/debian/tmp/etc/shibboleth/shibd-osx.plist