Sophie

Sophie

distrib > PLD > ra > i686 > by-pkgid > ae092fca0554559cc53152e082b0bc1f > scriptlet

utftpd-0.2.4-13.i686.rpm

PREIN

/bin/sh
if [ -n "`id -u tftp 2>/dev/null`" ]; then
	if [ "`id -u tftp`" != "15" ]; then
		echo "Error: user tftp doesn't have uid=15. Correct this before installing utftpd." 1>&2
		exit 1
	fi
else
	echo "Adding user tftp UID=15."
	/usr/sbin/useradd -u 15 -r -d /var/lib/tftp -s /bin/false -c "TFTP User" -g ftp tftp 1>&2
fi

POSTIN

/bin/sh
if [ -f /var/lock/subsys/rc-inetd ]; then
	/etc/rc.d/init.d/rc-inetd restart 1>&2
else
	echo "Type \"/etc/rc.d/init.d/rc-inetd start\" to start inet server." 1>&2
fi
echo -n "Rebuilding utftpd configuration... "
utftpd_make /etc/utftpd.cdb /etc/utftp.tmp /etc/utftpd.conf
echo "done"

POSTUN

/bin/sh
if [ -f /var/lock/subsys/rc-inetd ]; then
	/etc/rc.d/init.d/rc-inetd restart
fi

if [ "$1" = "0" ]; then
	echo "Removing user tftp."
	/usr/sbin/userdel tftp
fi