forked from freifunk-franken/firmware
packages/fff: add new fff-babeld package
Signed-off-by: Tim Niemeyer <tim@tn-x.org> Signed-off-by: Fabian Bläse <fabian@blaese.de> - Convert configuration to uci - Split IPv4 network rules to fff specific subnets - Add IPv6 ULA network rules - Change PKG_VERSION to single number versioning Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de> - Removed "delete batman-adv.bat0" Reviewed-by: Christian Dresel <fff@chrisi01.de> Reviewed-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
This commit is contained in:
parent
0a63717ab1
commit
23a81ffb9a
|
@ -40,7 +40,7 @@ ROUTING=(routing
|
|||
https://git.openwrt.org/feed/routing.git
|
||||
1b9d1c419f0ecefda51922a7845ab2183d6acd76
|
||||
"0002-Add-batman-adv-patch-to-remove-gw-mode-switch-messag.patch") # openwrt-18.06 from 2018-06-13
|
||||
ROUTING_PKGS="kmod-batman-adv batctl alfred"
|
||||
ROUTING_PKGS="kmod-batman-adv batctl alfred babeld"
|
||||
|
||||
FFF=(fff)
|
||||
FFF_PKGS="-a"
|
||||
|
|
|
@ -0,0 +1,40 @@
|
|||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=fff-babeld
|
||||
PKG_VERSION:=1
|
||||
PKG_RELEASE:=1
|
||||
|
||||
PKG_BUILD_DIR:=$(BUILD_DIR)/fff-babeld
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/fff-babeld
|
||||
SECTION:=base
|
||||
CATEGORY:=Freifunk
|
||||
TITLE:=Freifunk-Franken babeld configuration example
|
||||
URL:=http://www.freifunk-franken.de
|
||||
DEPENDS:=+babeld
|
||||
endef
|
||||
|
||||
define Package/fff-babeld/description
|
||||
This is the Freifunk Franken Firmware babeld package.
|
||||
This package provides an example babeld configuration.
|
||||
endef
|
||||
|
||||
define Build/Prepare
|
||||
echo "all: " > $(PKG_BUILD_DIR)/Makefile
|
||||
endef
|
||||
|
||||
define Build/Configure
|
||||
# nothing
|
||||
endef
|
||||
|
||||
define Build/Compile
|
||||
# nothing
|
||||
endef
|
||||
|
||||
define Package/fff-babeld/install
|
||||
$(CP) ./files/* $(1)/
|
||||
endef
|
||||
|
||||
$(eval $(call BuildPackage,fff-babeld))
|
|
@ -0,0 +1,40 @@
|
|||
config general
|
||||
option export_table '10'
|
||||
option import_table '10'
|
||||
option first_table_number '100'
|
||||
option local_port '33123'
|
||||
|
||||
config interface
|
||||
option type 'wired'
|
||||
|
||||
config filter
|
||||
option type 'redistribute'
|
||||
option local 'true'
|
||||
option ip '10.50.0.0/16'
|
||||
|
||||
config filter
|
||||
option type 'redistribute'
|
||||
option local 'true'
|
||||
option ip '10.83.0.0/16'
|
||||
|
||||
config filter
|
||||
option type 'redistribute'
|
||||
option local 'true'
|
||||
option ip 'fd43:5602:29bd::/48'
|
||||
|
||||
config filter
|
||||
option type 'redistribute'
|
||||
option local 'true'
|
||||
option action 'deny'
|
||||
|
||||
config filter
|
||||
option type 'redistribute'
|
||||
option ip '10.50.0.0/16'
|
||||
|
||||
config filter
|
||||
option type 'redistribute'
|
||||
option ip '10.83.0.0/16'
|
||||
|
||||
config filter
|
||||
option type 'redistribute'
|
||||
option ip 'fd43:5602:29bd::/48'
|
|
@ -0,0 +1,3 @@
|
|||
#!/bin/sh
|
||||
|
||||
echo "10 fff" >> /etc/iproute2/rt_tables
|
|
@ -0,0 +1,46 @@
|
|||
#!/bin/sh
|
||||
|
||||
uci batch <<EOF
|
||||
add network rule
|
||||
set network.@rule[0].src='10.50.0.0/16'
|
||||
set network.@rule[0].lookup='10'
|
||||
set network.@rule[0].priority='20'
|
||||
add network rule
|
||||
set network.@rule[1]=rule
|
||||
set network.@rule[1].dest='10.50.0.0/16'
|
||||
set network.@rule[1].lookup='10'
|
||||
set network.@rule[1].priority='20'
|
||||
add network rule
|
||||
set network.@rule[2].src='10.83.0.0/16'
|
||||
set network.@rule[2].lookup='10'
|
||||
set network.@rule[2].priority='20'
|
||||
add network rule
|
||||
set network.@rule[3]=rule
|
||||
set network.@rule[3].dest='10.83.0.0/16'
|
||||
set network.@rule[3].lookup='10'
|
||||
set network.@rule[3].priority='20'
|
||||
add network rule
|
||||
set network.@rule[4]=rule
|
||||
set network.@rule[4].in='mesh'
|
||||
set network.@rule[4].lookup='10'
|
||||
set network.@rule[4].priority='31'
|
||||
add network rule6
|
||||
set network.@rule6[0]=rule6
|
||||
set network.@rule6[0].src='fc00::/7'
|
||||
set network.@rule6[0].lookup='10'
|
||||
set network.@rule6[0].priority='20'
|
||||
add network rule6
|
||||
set network.@rule6[1]=rule6
|
||||
set network.@rule6[1].dest='fc00::/7'
|
||||
set network.@rule6[1].lookup='10'
|
||||
set network.@rule6[1].priority='20'
|
||||
add network rule6
|
||||
set network.@rule6[2]=rule6
|
||||
set network.@rule6[2].in='mesh'
|
||||
set network.@rule6[2].lookup='10'
|
||||
set network.@rule6[2].priority='31'
|
||||
EOF
|
||||
|
||||
uci commit
|
||||
|
||||
exit 0
|
Loading…
Reference in New Issue