port lots of init scripts over to rc.common (more to come)
[packages.git] / net / rp-pppoe / files / pppoe-relay.init
index d8212f2..53878c3 100644 (file)
@@ -1,15 +1,14 @@
-#!/bin/sh
+#!/bin/sh /etc/rc.common
+# Copyright (C) 2006 OpenWrt.org
 
 DEFAULT=/etc/default/pppoe-relay
 [ -f $DEFAULT ] && . $DEFAULT
 
-case $1 in
- start)
-  pppoe-relay $OPTIONS
-  ;;
- *)
-  echo "usage: $0 (start)"
-  exit 1
-esac
+start() {
+       pppoe-relay $OPTIONS
+}
+
+stop() {
+       killall pppoe-relay
+}
 
-exit $?