#!/bin/sh # postinst script for postsrsd # # 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 if [ "$1" = "configure" -a ! -f /etc/postsrsd.secret ] then echo "postsrsd: Generating initial /etc/postsrsd.secret" >&2 ( umask 0077 ; dd if=/dev/urandom bs=18 count=1 2>/dev/null | base64 -w0 > /etc/postsrsd.secret ) fi if [ "$1" = "configure" -o "$1" = "abort-deconfigure" -o "$1" = "abort-remove" ] then if [ -x /sbin/apparmor_parser ] then apparmor_parser -r -W -T /etc/apparmor.d/usr.sbin.postsrsd fi fi # dh_installdeb will replace this with shell code automatically # generated by other debhelper scripts. #DEBHELPER# exit 0