From patchwork Thu Aug 6 23:33:48 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: [RFC] Add package fff-vxlan-node From: Robert Langhammer X-Patchwork-Id: 1423 Message-Id: <20200806233348.4518-1-rlanghammer@web.de> To: franken-dev@freifunk.net Date: Fri, 7 Aug 2020 01:33:48 +0200 This package adds vxlan support to the node variant and configures the vxlan-vpn tunnels to the gateways. A vpn section has to be added to the hoodfile for every peer (GW) supporting vxlan: { "version": 1, "network": { "ula_prefix": "fd43:5602:29bd:16:\/64" }, "vpn": [ { "name": "rl-fff1-vx", "protocol": "vxlan", "vid": "7", "address": "rl-fff1.fff.community" }, { "name": "fff-gw-mc", "protocol": "fastd", ... For testing the hoods schweinfurt, hassfurt, coburg, ebern and geo can be used. "address" is the same for all hoods: rl-fff1.fff.community. The respective hood-id is used as vid. This patch depends on "[RFC,v2] vxlan: netifd and vxlan package patches" and "Make vpn select modular.patch" Happy testing! Signed-off-by: Robert Langhammer --- src/packages/fff/fff-node/Makefile | 3 +- src/packages/fff/fff-vxlan-node/Makefile | 39 +++++++++++++++++++ .../files/etc/uci-defaults/55-vxlan | 15 +++++++ .../files/etc/vpn-select.d/vxlan | 26 +++++++++++++ 4 files changed, 82 insertions(+), 1 deletion(-) create mode 100644 src/packages/fff/fff-vxlan-node/Makefile create mode 100644 src/packages/fff/fff-vxlan-node/files/etc/uci-defaults/55-vxlan create mode 100644 src/packages/fff/fff-vxlan-node/files/etc/vpn-select.d/vxlan -- 2.20.1 diff --git a/src/packages/fff/fff-node/Makefile b/src/packages/fff/fff-node/Makefile index 0292725..8b31202 100644 --- a/src/packages/fff/fff-node/Makefile +++ b/src/packages/fff/fff-node/Makefile @@ -1,7 +1,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=fff-node -PKG_RELEASE:=2 +PKG_RELEASE:=3 PKG_BUILD_DIR:=$(BUILD_DIR)/fff-node @@ -14,6 +14,7 @@ define Package/fff-node URL:=https://www.freifunk-franken.de DEPENDS:=+fff-batman-adv \ +fff-fastd \ + +fff-vxlan-node \ +fff-firewall \ +fff-hoods \ +fff-uradvd diff --git a/src/packages/fff/fff-vxlan-node/Makefile b/src/packages/fff/fff-vxlan-node/Makefile new file mode 100644 index 0000000..233badd --- /dev/null +++ b/src/packages/fff/fff-vxlan-node/Makefile @@ -0,0 +1,39 @@ +include $(TOPDIR)/rules.mk + +PKG_NAME:=fff-vxlan-node +PKG_RELEASE:=1 + +PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME) + +include $(INCLUDE_DIR)/package.mk + +define Package/$(PKG_NAME) + SECTION:=base + CATEGORY:=Freifunk + TITLE:=Freifunk-Franken vxlan-node configuration + URL:=http://www.freifunk-franken.de + DEPENDS:=+vxlan +endef + +define Package/$(PKG_NAME)/description + This is the vxlan for the Freifunk Franken node-Firmware + It is used to configure vxlan. +endef + +define Build/Prepare + echo "all: " > $(PKG_BUILD_DIR)/Makefile +endef + +define Build/Configure + # nothing +endef + +define Build/Compile + # nothing +endef + +define Package/$(PKG_NAME)/install + $(CP) ./files/* $(1)/ +endef + +$(eval $(call BuildPackage,$(PKG_NAME))) diff --git a/src/packages/fff/fff-vxlan-node/files/etc/uci-defaults/55-vxlan b/src/packages/fff/fff-vxlan-node/files/etc/uci-defaults/55-vxlan new file mode 100644 index 0000000..2e6ab69 --- /dev/null +++ b/src/packages/fff/fff-vxlan-node/files/etc/uci-defaults/55-vxlan @@ -0,0 +1,15 @@ +uci batch <