diff options
author | Steven Barth <cyrus@openwrt.org> | 2014-10-08 20:37:15 +0000 |
---|---|---|
committer | Steven Barth <cyrus@openwrt.org> | 2014-10-08 20:37:15 +0000 |
commit | c62b07b2ce55b16c976a1b87ca80a39c1127d612 (patch) | |
tree | af1dbe03bd25d8d15ce1c705b8d3aaaef965ea8a /package/network/services/ppp/files/lib/netifd/ppp-up | |
parent | ea0a01d7e20b407721742b4e4a7efbc258aab7a5 (diff) | |
download | upstream-c62b07b2ce55b16c976a1b87ca80a39c1127d612.tar.gz upstream-c62b07b2ce55b16c976a1b87ca80a39c1127d612.tar.bz2 upstream-c62b07b2ce55b16c976a1b87ca80a39c1127d612.zip |
ppp: allow auto-detecting and creation of ipv6 subinterface
this makes ipv6 with ppp a bit more comfortable
Signed-off-by: Steven Barth <steven@midlink.org>
SVN-Revision: 42854
Diffstat (limited to 'package/network/services/ppp/files/lib/netifd/ppp-up')
-rwxr-xr-x | package/network/services/ppp/files/lib/netifd/ppp-up | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/package/network/services/ppp/files/lib/netifd/ppp-up b/package/network/services/ppp/files/lib/netifd/ppp-up index fa14550ec4..286fc5f834 100755 --- a/package/network/services/ppp/files/lib/netifd/ppp-up +++ b/package/network/services/ppp/files/lib/netifd/ppp-up @@ -19,3 +19,12 @@ proto_send_update "$PPP_IPPARAM" [ -x "$SCRIPT" ] && "$SCRIPT" "$@" done } + +if [ -n "$IPV6IFACE" -a "$(ifstatus $IPV6IFACE | jsonfilter -e @.device)" != "$IFNAME" ]; then + json_init + json_add_string name "${PPP_IPPARAM}_dhcpv6" + json_add_string ifname "@$PPP_IPPARAM" + json_add_string proto "dhcpv6" + json_close_object + ubus call network add_dynamic "$(json_dump)" +fi |