From 4bba36d56be9760aafd07c9883d8e734bda4cc40 Mon Sep 17 00:00:00 2001 From: Florian Fainelli Date: Fri, 21 Dec 2007 09:34:01 +0000 Subject: [PATCH] Add init files and iptables rule for ptunnel to work (#2863) Signed-off-by: michu-at-neophob-com SVN-Revision: 9818 --- net/ptunnel/Makefile | 2 ++ net/ptunnel/files/ptunnel.init | 14 ++++++++++++++ 2 files changed, 16 insertions(+) create mode 100644 net/ptunnel/files/ptunnel.init diff --git a/net/ptunnel/Makefile b/net/ptunnel/Makefile index 39dc30a3f3..d4aada558c 100644 --- a/net/ptunnel/Makefile +++ b/net/ptunnel/Makefile @@ -47,6 +47,8 @@ endef define Package/ptunnel/install $(INSTALL_DIR) $(1)/usr/sbin $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/ptunnel $(1)/usr/sbin/ + $(INSTALL_DIR) $(1)/etc/init.d + $(INSTALL_BIN) ./files/ptunnel.init $(1)/etc/init.d/ptunnel endef $(eval $(call BuildPackage,ptunnel)) diff --git a/net/ptunnel/files/ptunnel.init b/net/ptunnel/files/ptunnel.init new file mode 100644 index 0000000000..da3b143372 --- /dev/null +++ b/net/ptunnel/files/ptunnel.init @@ -0,0 +1,14 @@ +#!/bin/sh /etc/rc.common +# Copyright (C) 2007 OpenWrt.org +START=70 +STOP=70 + +start() { + iptables -I OUTPUT 1 -p icmp -j ACCEPT + ptunnel -v 1 -c br-lan +} + +stop() { + killall ptunnel +} + \ No newline at end of file -- 2.30.2