Sophie

Sophie

distrib > Fedora > 14 > i386 > by-pkgid > 63a1188af44ae810209e571b20976208 > scriptlet

nut-client-2.6.2-1.fc14.i686.rpm

PREIN

/bin/sh
/usr/sbin/useradd -c "Network UPS Tools" -u 57 \
        -s /bin/false -r -d /var/lib/ups nut 2> /dev/null || :
/usr/sbin/usermod -G dialout nut

PREUN

/bin/sh
if [ "$1" = "0" ]; then
    /sbin/service ups stop > /dev/null 2>&1
    /sbin/chkconfig --del ups
    rm -rf /var/run/nut
fi
/sbin/ldconfig
exit 0

POSTIN

/bin/sh
install -d -m 0750 -o nut -g nut /var/run/nut
/sbin/chkconfig --add ups
/sbin/ldconfig
exit 0

POSTUN

/bin/sh
if [ "$1" -ge "1" ]; then
    /sbin/service ups condrestart > /dev/null 2>&1
fi
/sbin/ldconfig
exit 0