summaryrefslogtreecommitdiffstats
path: root/package/vsftpd/vsftpd-init
diff options
context:
space:
mode:
Diffstat (limited to 'package/vsftpd/vsftpd-init')
-rwxr-xr-xpackage/vsftpd/vsftpd-init33
1 files changed, 33 insertions, 0 deletions
diff --git a/package/vsftpd/vsftpd-init b/package/vsftpd/vsftpd-init
new file mode 100755
index 000000000..6048907f6
--- /dev/null
+++ b/package/vsftpd/vsftpd-init
@@ -0,0 +1,33 @@
+#! /bin/sh
+
+set -e
+
+DESC="vsftpd"
+NAME=vsftpd
+DAEMON=/usr/sbin/$NAME
+
+case "$1" in
+ start)
+ echo -n "Starting $DESC: "
+ start-stop-daemon -S -b -x $NAME
+ echo "OK"
+ ;;
+ stop)
+ echo -n "Stopping $DESC: "
+ start-stop-daemon -K -x $NAME
+ echo "OK"
+ ;;
+ restart|force-reload)
+ echo "Restarting $DESC: "
+ $0 stop
+ sleep 1
+ $0 start
+ echo ""
+ ;;
+ *)
+ echo "Usage: $0 {start|stop|restart|force-reload}" >&2
+ exit 1
+ ;;
+esac
+
+exit 0