summaryrefslogtreecommitdiff
path: root/tests/unittests/test_net.py
diff options
context:
space:
mode:
authorRyan Harper <ryan.harper@canonical.com>2017-06-15 11:51:54 -0500
committerScott Moser <smoser@brickies.net>2017-07-20 14:58:34 -0400
commit31fa6f9d0f945868349c033fa049d2467ddcd478 (patch)
tree85b73913b0d2bb3b9d0c88a78ffe8bbca8fd21e7 /tests/unittests/test_net.py
parent51febf7363692d7947fe17a4fbfcb85058168ccb (diff)
downloadvyos-cloud-init-31fa6f9d0f945868349c033fa049d2467ddcd478.tar.gz
vyos-cloud-init-31fa6f9d0f945868349c033fa049d2467ddcd478.zip
sysconfig: fix ipv6 gateway routes
Currently only the subnet is checked for 'ipv6' setting, however, the routes array may include a mix of v4 or v6 configurations, in particular, the gateway in a route may be ipv6, and if so, should export the value via IPV6_DEFAULTGW in the ifcfg-XXXX file. Additionally, if the route is v6, it should rendering a routes6-XXXX file; this is present but missing the 'dev <interface>' scoping. LP: #1694801
Diffstat (limited to 'tests/unittests/test_net.py')
-rw-r--r--tests/unittests/test_net.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/unittests/test_net.py b/tests/unittests/test_net.py
index f786eea0..c012600f 100644
--- a/tests/unittests/test_net.py
+++ b/tests/unittests/test_net.py
@@ -949,11 +949,12 @@ pre-down route del -net 10.0.0.0 netmask 255.0.0.0 gw 11.0.0.1 metric 3 || true
BOOTPROTO=none
DEFROUTE=yes
DEVICE=en0.99
- GATEWAY=2001:1::1
+ GATEWAY=192.168.1.1
IPADDR=192.168.2.2
IPADDR1=192.168.1.2
IPV6ADDR=2001:1::bbbb/96
IPV6INIT=yes
+ IPV6_DEFAULTGW=2001:1::1
NETMASK=255.255.255.0
NETMASK1=255.255.255.0
NM_CONTROLLED=no