1 #!/bin/sh /etc/rc.common
2 # Copyright (C) 2010 OpenWrt.org
9 PID_F=$RUN_D/proftpd.pid
13 EXTRA_COMMANDS="suspend resume"
14 EXTRA_HELP=" suspend Suspend the service
15 resume Resume the service"
18 [ -d $HOME ] || ( mkdir -p $HOME && chown $RUN_USER:$RUN_GROUP $HOME )
20 [ ! -f $PID_F ] && $BIN
24 [ -f $PID_F ] && kill $(cat $PID_F)
28 [ -f $PID_F ] && kill -HUP $(cat $PID_F)
33 ftpshut now "Maintenance in progress"
37 [ -f /etc/shutmsg ] && {
38 echo "Allowing sessions again"
39 ftpshut -R > /dev/null