init script cleanup, use /etc/rc.d/ for enabled scripts, /etc/init.d/<pkgname> (enable|disable) manages symlinks
git-svn-id: svn://svn.openwrt.org/openwrt/packages@5128 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
@ -42,7 +42,6 @@ endef
|
||||
define Package/reaim/install
|
||||
install -d -m0755 $(1)/etc/init.d
|
||||
install -m0755 ./files/reaim.init $(1)/etc/init.d/reaim
|
||||
ln -sf reaim $(1)/etc/init.d/S63reaim
|
||||
install -d -m0755 $(1)/usr/sbin
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/sbin/reaim $(1)/usr/sbin/
|
||||
endef
|
||||
|
@ -1,16 +1,17 @@
|
||||
#!/bin/sh /etc/rc.common
|
||||
# Copyright (C) 2006 OpenWrt.org
|
||||
|
||||
START=60
|
||||
PATH=/sbin:/bin:/usr/sbin:/usr/bin
|
||||
NAME=reaim
|
||||
DESC="Transparent proxy for IM behind NAT"
|
||||
IPT=/usr/sbin/iptables
|
||||
|
||||
include /lib/network
|
||||
scan_interfaces
|
||||
config_get WAN wan ifname
|
||||
|
||||
set_rules() {
|
||||
include /lib/network
|
||||
scan_interfaces
|
||||
config_get WAN wan ifname
|
||||
|
||||
[ -z "$WAN" ] && exit
|
||||
$IPT $1 input_rule -i $WAN -p tcp --dport 1863:1864 -j ACCEPT
|
||||
$IPT $1 input_rule -i $WAN -p tcp --dport 4443 -j ACCEPT
|
||||
|
Reference in New Issue
Block a user