diff options
author | Wataru Ishida <ishida.wataru@lab.ntt.co.jp> | 2016-11-04 13:19:47 +0900 |
---|---|---|
committer | FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> | 2016-11-04 13:19:47 +0900 |
commit | a17832195c5fc42d6d0ec3dd7cc4868694bed88d (patch) | |
tree | 14381d27f1e58a6c399de90cc206d2433d8d366f /test/lib | |
parent | 97bc9dd0da71ce743dbb7deb4a09f260ca518dcc (diff) |
support neighbor belongs to VRF
$ gobgp vrf add red rd 100:100 rt both 100:100
$ gobgp neighbor add 10.0.0.1 as 2 vrf red
$ gobgp vrf red neighbor
Peer AS Up/Down State |#Advertised Received Accepted
10.0.0.1 2 never Active | 0 0 0
Signed-off-by: Wataru Ishida <ishida.wataru@lab.ntt.co.jp>
Diffstat (limited to 'test/lib')
-rw-r--r-- | test/lib/base.py | 5 | ||||
-rw-r--r-- | test/lib/gobgp.py | 1 |
2 files changed, 4 insertions, 2 deletions
diff --git a/test/lib/base.py b/test/lib/base.py index 3d14cf4c..5f73b45d 100644 --- a/test/lib/base.py +++ b/test/lib/base.py @@ -280,7 +280,7 @@ class BGPContainer(Container): is_rr_client=False, cluster_id=None, flowspec=False, bridge='', reload_config=True, as2=False, graceful_restart=None, local_as=None, prefix_limit=None, - v6=False, llgr=None): + v6=False, llgr=None, vrf=''): neigh_addr = '' local_addr = '' it = itertools.product(self.ip_addrs, peer.ip_addrs) @@ -318,7 +318,8 @@ class BGPContainer(Container): 'graceful_restart': graceful_restart, 'local_as': local_as, 'prefix_limit': prefix_limit, - 'llgr': llgr} + 'llgr': llgr, + 'vrf': vrf} if self.is_running and reload_config: self.create_config() self.reload_config() diff --git a/test/lib/gobgp.py b/test/lib/gobgp.py index 77060893..29a116a8 100644 --- a/test/lib/gobgp.py +++ b/test/lib/gobgp.py @@ -277,6 +277,7 @@ class GoBGPContainer(BGPContainer): {'neighbor-address': info['neigh_addr'].split('/')[0], 'peer-as': peer.asn, 'auth-password': info['passwd'], + 'vrf': info['vrf'], }, 'afi-safis': afi_safi_list, 'timers': {'config': { |