summaryrefslogtreecommitdiffstats
path: root/openwrt/package/pptp/files/pptp.init
diff options
context:
space:
mode:
authornico <nico@3c298f89-4303-0410-b956-a3cf2f4a3e73>2005-05-18 23:42:09 +0000
committernico <nico@3c298f89-4303-0410-b956-a3cf2f4a3e73>2005-05-18 23:42:09 +0000
commit57b3da14cd145a03f399b29b5e9eb15206f6cc79 (patch)
treebc89a13663db6b74780802837517151735dc5bd1 /openwrt/package/pptp/files/pptp.init
parent01e3a7a8b0ff683476f1efc4240660a713428183 (diff)
Convert pptp to new packaging style
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@941 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'openwrt/package/pptp/files/pptp.init')
-rw-r--r--openwrt/package/pptp/files/pptp.init18
1 files changed, 18 insertions, 0 deletions
diff --git a/openwrt/package/pptp/files/pptp.init b/openwrt/package/pptp/files/pptp.init
new file mode 100644
index 000000000..34ff8a63b
--- /dev/null
+++ b/openwrt/package/pptp/files/pptp.init
@@ -0,0 +1,18 @@
+#!/bin/sh
+
+. /etc/functions.sh
+
+WAN_PROTO=$(nvram get wan_proto)
+[ "$WAN_PROTO" = "pptp" ] || exit 0
+
+for module in ip_gre slhc ppp_generic ppp_async ppp_deflate ; do
+ /sbin/insmod $module 2>/dev/null >/dev/null
+done
+
+if test -d "/var/lock"; then
+ mkdir -p /var/lock || exit 1
+fi
+
+/usr/sbin/pppd pty "pptp x.x.x.x --loglevel 0 --nolaunchpppd" file /etc/ppp/options.pptp
+
+