summaryrefslogtreecommitdiffstats
path: root/package/chillispot/ipkg/etc/init.d
diff options
context:
space:
mode:
Diffstat (limited to 'package/chillispot/ipkg/etc/init.d')
-rwxr-xr-xpackage/chillispot/ipkg/etc/init.d/S60chilli16
1 files changed, 16 insertions, 0 deletions
diff --git a/package/chillispot/ipkg/etc/init.d/S60chilli b/package/chillispot/ipkg/etc/init.d/S60chilli
new file mode 100755
index 000000000..0fded5b13
--- /dev/null
+++ b/package/chillispot/ipkg/etc/init.d/S60chilli
@@ -0,0 +1,16 @@
+#!/bin/sh
+case $1 in
+ start)
+ /sbin/insmod tun >/dev/null 2>&1
+ [ -d /var/run ] || mkdir -p /var/run
+ /usr/sbin/chilli
+ ;;
+ stop)
+ [ -f /var/run/chilli.pid ] && kill $(cat /var/run/chilli.pid) >/dev/null 2>&1
+ ;;
+ *)
+ echo "usage: $0 (start|stop)"
+ exit 1
+esac
+
+exit $?