Sophie

Sophie

distrib > PLD > ac > amd64 > by-pkgid > 8c437dda0fea73b5e701fdaab8ae3f15 > scriptlet

bacula-fd-1.38.11-1.amd64.rpm

PREUN

/bin/sh
if [ "$1" = "0" ]; then
	{
if [ -f /var/lock/subsys/bacula-fd ]; then
/sbin/service bacula-fd stop 1>&2 || :;
fi };	/sbin/chkconfig --del bacula-fd
fi

POSTIN

/bin/sh
echo "Updating Bacula passwords and names..."
cd /etc/bacula
for f in *-password ; do
	p=`cat $f`
	sed -i -e"s:#FAKE-$f#:$p:" *.conf *.conf.rpmnew 2>/dev/null || :
done
sed -i -e"s:--hostname--:`hostname`:" *.conf *.conf.rpmnew 2>/dev/null || :

/sbin/chkconfig --add bacula-fd
{
skip_auto_restart() {
[ -f /etc/sysconfig/rpm ] && . /etc/sysconfig/rpm
[ -f /etc/sysconfig/bacula-fd ] && . /etc/sysconfig/bacula-fd
echo ${RPM_SKIP_AUTO_RESTART:-no}
};
if [ $(skip_auto_restart) = no ]; then
if [ -f /var/lock/subsys/bacula-fd ]; then
/sbin/service bacula-fd restart 1>&2 || :;
else
echo 'Run "/sbin/service bacula-fd start" to start Bacula File daemon.'
fi
fi };