From dc05441b446aa4cf7e6eaa941c6dd623131bdcff Mon Sep 17 00:00:00 2001 From: LV-426 Date: Sun, 3 May 2015 16:51:39 +0300 Subject: deb-pkg, build.ant: introducing 'single' and 'mux' debian package variants Currently both share the same control script, generating a 'rhizi' named package --- res/debian/pkg__rhizi-mux/postinst | 52 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 res/debian/pkg__rhizi-mux/postinst (limited to 'res/debian/pkg__rhizi-mux/postinst') diff --git a/res/debian/pkg__rhizi-mux/postinst b/res/debian/pkg__rhizi-mux/postinst new file mode 100644 index 00000000..44b87c5f --- /dev/null +++ b/res/debian/pkg__rhizi-mux/postinst @@ -0,0 +1,52 @@ +#!/bin/sh +# postinst script for rhizi +# +# see: dh_installdeb(1) + +set -e + +# summary of how this script can be called: +# * `configure' +# * `abort-upgrade' +# * `abort-remove' `in-favour' +# +# * `abort-remove' +# * `abort-deconfigure' `in-favour' +# `removing' +# +# for details, see http://www.debian.org/doc/debian-policy/ or +# the debian-policy package + + +case "$1" in + configure) + # call chmod, chown, etc. + + chown www-data:www-data /var/run/rhizi + chown www-data:www-data /var/log/rhizi + + # configure apache - FIXME: impl undo + echo 'enabling apache proxy modules - warning: this will not be reverted during package uninstall' + /usr/sbin/a2enmod deflate + /usr/sbin/a2enmod proxy + /usr/sbin/a2enmod proxy_http + /usr/sbin/a2enmod proxy_wstunnel + /usr/sbin/a2enmod rewrite + + ;; + + abort-upgrade|abort-remove|abort-deconfigure) + ;; + + *) + echo "postinst called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +# dh_installdeb will replace this with shell code automatically +# generated by other debhelper scripts. + +#DEBHELPER# + +exit 0 -- cgit v1.3.1