Sophie

Sophie

distrib > Fedora > 16 > i386 > by-pkgid > 6078952f32fc06a1185913d7abced47c > scriptlet

arm4-0.8.2-8.fc16.i686.rpm

PREIN

/bin/sh
# Add the arm4 user and group
getent group arm4 >/dev/null || groupadd -r arm4
getent passwd arm4 >/dev/null || \
	useradd -r -g arm4 -d /var/lib/arm4 -s /sbin/nologin \
	-c "ARM 4 Daemon" arm4
exit 0

PREUN

/bin/sh
if [ $1 -eq 0 ] ; then
    # Package removal, not upgrade
    /bin/systemctl --no-reload disable arm4.service > /dev/null 2>&1 || :
    /bin/systemctl stop arm4.service > /dev/null 2>&1 || :
fi

POSTIN

/bin/sh
if [ $1 -eq 1 ] ; then 
    # Initial installation 
    /bin/systemctl daemon-reload >/dev/null 2>&1 || :
fi
/sbin/ldconfig

POSTUN

/bin/sh
/bin/systemctl daemon-reload >/dev/null 2>&1 || :
if [ $1 -ge 1 ] ; then
    # Package upgrade, not uninstall
    /bin/systemctl try-restart arm4.service >/dev/null 2>&1 || :
fi
/sbin/ldconfig

Triggers

arm4 < 0.8.2-7

/bin/sh
# Save the current service runlevel info
# User must manually run systemd-sysv-convert --apply arm4
# to migrate them to systemd targets
/usr/bin/systemd-sysv-convert --save arm4 >/dev/null 2>&1 ||:

# Run these because the SysV package being removed won't do them
/sbin/chkconfig --del arm4 >/dev/null 2>&1 || :
/bin/systemctl try-restart arm4.service >/dev/null 2>&1 || :