Sophie

Sophie

distrib > Fedora > 14 > i386 > by-pkgid > 085795f0f2aff135b5db3bf33d87fe47 > scriptlet

unbound-1.4.5-2.fc14.i686.rpm

PREIN

/bin/sh
getent group unbound >/dev/null || groupadd -r unbound
getent passwd unbound >/dev/null || \
useradd -r -g unbound -d /etc/unbound -s /sbin/nologin \
-c "Unbound DNS resolver" unbound
exit 0

PREUN

/bin/sh
if [ "$1" -eq 0 ]; then
        /sbin/service unbound stop >/dev/null 2>&1
        /sbin/chkconfig --del unbound 
fi

POSTIN

/bin/sh
/sbin/chkconfig --add unbound
# dnssec-conf used to contain our DLV key, but now we include it via unbound
# If unbound had previously been configured with dnssec-configure, we need
# to migrate the location of the DLV key file (to keep DLV enabled, and because
# unbound won't start with a bad location for a DLV key file.
sed -i "s:/etc/pki/dnssec-keys[/]*dlv:/etc/unbound:" /etc/unbound/unbound.conf

POSTUN

/bin/sh
if [ "$1" -ge "1" ]; then
  /sbin/service unbound condrestart >/dev/null 2>&1 || :
fi