Sophie

Sophie

distrib > Mageia > 1 > i586 > by-pkgid > 2e9827d1701769dd377c6356b2084cf2 > scriptlet

proftpd-1.3.3e-3.mga1.i586.rpm

PREIN

/bin/sh
/usr/share/rpm-helper/add-user proftpd $1 ftp /var/ftp /bin/false

PREUN

/bin/sh
/usr/share/rpm-helper/del-service proftpd $1 proftpd 
if [ "$1" = 0 ]; then
 if [ -d /var/run/proftpd ]; then
  rm -rf /var/run/proftpd/*
 fi
fi

if [ -x /usr/sbin/xinetd ];then
/usr/share/rpm-helper/add-service proftpd $1 xinetd 
fi

POSTIN

/bin/sh
/usr/share/rpm-helper/add-service proftpd $1 proftpd 

# xinetd reset
# Only do it if xinetd is there. -- Geoff
if [ -x /usr/sbin/xinetd ];then
/usr/share/rpm-helper/add-service proftpd $1 xinetd 
fi

# ftpusers creation
if [ ! -f /etc/ftpusers ]; then
    touch /etc/ftpusers
fi

USERS="root bin daemon adm lp sync shutdown halt mail news uucp operator games nobody"
for i in $USERS ;do
        cat /etc/ftpusers | grep -q "^$i$" || echo $i >> /etc/ftpusers
done

POSTUN

/bin/sh
/usr/share/rpm-helper/del-user proftpd $1 ftp

Triggers

proftpd-anonymous

/bin/sh
# this package doesn't exist anymore, but its configuration file may
# be used in current proftpd configuration
if [ -e /etc/proftpd-anonymous.conf.rpmsave ]; then
    mv -f /etc/proftpd-anonymous.conf.rpmsave /etc/proftpd-anonymous.conf
    echo "warning: /etc/proftpd-anonymous.conf.rpmsave restored as /etc/proftpd-anonymous.conf"
fi