#!/bin/sh # # License: GNU General Public License (GPL) # # postinst script for heartbeat # # see: dh_installdeb(1) set -e # summary of how this script can be called: # * `configure' # * `abort-upgrade' # * `abort-remove' `in-favour' # # * `abort-deconfigure' `in-favour' # `removing' # # case "$1" in configure) addgroup --system haclient adduser --system hacluster --ingroup haclient --home /var/lib/heartbeat for i in /var/run/heartbeat/crm /var/lib/heartbeat/crm \ /var/lib/heartbeat/pengine /var/lib/pengine; do if [ ! -d $i ]; then mkdir -p $i fi chown hacluster $i chgrp haclient $i done chmod 750 /var/lib/pengine ;; purge) id haclient >/dev/null 2>&1; if [ "x$?" = "x0" ]; then userdel -rf haclient && groupdel hacluster; fi rm -rf /var/lib/openais rm -rf /var/log/openais ;; abort-upgrade|abort-remove|abort-deconfigure) ;; *) echo "postinst called with unknown argument \`$1'" >&2 exit 0 ;; esac pycentral pkginstall pacemaker # dh_installdeb will replace this with shell code automatically # generated by other debhelper scripts. #DEBHELPER# exit 0