aboutsummaryrefslogtreecommitdiffstats
path: root/package/chillispot/ipkg/chillispot.init
diff options
context:
space:
mode:
authorNicolas Thill <nico@openwrt.org>2005-04-18 21:42:27 +0000
committerNicolas Thill <nico@openwrt.org>2005-04-18 21:42:27 +0000
commitdfcdfa63eb488bf4354d44ba5d72674730c976b2 (patch)
tree8a750dfc30d2d6262a1e846461c70679d76e1e8d /package/chillispot/ipkg/chillispot.init
parent5a816cbb20bff4c563ec449a20ac3bbfc22e1433 (diff)
downloadupstream-dfcdfa63eb488bf4354d44ba5d72674730c976b2.tar.gz
upstream-dfcdfa63eb488bf4354d44ba5d72674730c976b2.tar.bz2
upstream-dfcdfa63eb488bf4354d44ba5d72674730c976b2.zip
Update chillispot to 1.0RC3, uniformize package Makefile, move ipkg related files to ./ipkg, add conffiles
git-svn-id: svn://svn.openwrt.org/openwrt/trunk/openwrt@679 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'package/chillispot/ipkg/chillispot.init')
-rw-r--r--package/chillispot/ipkg/chillispot.init20
1 files changed, 20 insertions, 0 deletions
diff --git a/package/chillispot/ipkg/chillispot.init b/package/chillispot/ipkg/chillispot.init
new file mode 100644
index 0000000000..289b1fe8a5
--- /dev/null
+++ b/package/chillispot/ipkg/chillispot.init
@@ -0,0 +1,20 @@
+#!/bin/sh
+
+RUN_D=/var/run
+PID_F=$RUN_D/chilli.pid
+
+case $1 in
+ start)
+ /sbin/insmod tun >/dev/null 2>&1
+ [ -d $RUN_D ] || mkdir -p $RUN_D
+ /usr/sbin/chilli
+ ;;
+ stop)
+ [ -f $PID_F ] && kill $(cat $PID_F) >/dev/null 2>&1
+ ;;
+ *)
+ echo "usage: $0 (start|stop)"
+ exit 1
+esac
+
+exit $?