6rd: add 6rd specific settings as nested json object
Add 6rd specific settings prefix, relay-prefix as a nested data json object Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
This commit is contained in:
parent
5f2408dbc5
commit
c0a9a73393
2 changed files with 7 additions and 3 deletions
|
@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
|
|||
|
||||
PKG_NAME:=6rd
|
||||
PKG_VERSION:=9
|
||||
PKG_RELEASE:=2
|
||||
PKG_RELEASE:=3
|
||||
PKG_LICENSE:=GPL-2.0
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
|
|
@ -64,9 +64,13 @@ proto_6rd_setup() {
|
|||
json_add_int ttl "${ttl:-64}"
|
||||
[ -n "$tos" ] && json_add_string tos "$tos"
|
||||
json_add_string local "$ipaddr"
|
||||
json_add_string 6rd-prefix "$ip6prefix/$ip6prefixlen"
|
||||
json_add_string 6rd-relay-prefix "$ip4prefix/$ip4prefixlen"
|
||||
[ -n "$tunlink" ] && json_add_string link "$tunlink"
|
||||
|
||||
json_add_object 'data'
|
||||
json_add_string prefix "$ip6prefix/$ip6prefixlen"
|
||||
json_add_string relay-prefix "$ip4prefix/$ip4prefixlen"
|
||||
json_close_object
|
||||
|
||||
proto_close_tunnel
|
||||
|
||||
proto_add_data
|
||||
|
|
Loading…
Reference in a new issue