diff options
author | ISHIDA Wataru <ishida.wataru@lab.ntt.co.jp> | 2015-08-22 11:33:14 +0900 |
---|---|---|
committer | ISHIDA Wataru <ishida.wataru@lab.ntt.co.jp> | 2015-08-22 13:07:13 +0900 |
commit | da62a698664abaf0f8d321824b5ee69f2cf0fba4 (patch) | |
tree | 4a5d99f8f10b00f25db2e31534c055fb1a82e3ff /policy/policy.go | |
parent | 424ff51342c6691ee136c82b3199f2aeb2983f23 (diff) |
api/cli: support showing extended community action
Signed-off-by: ISHIDA Wataru <ishida.wataru@lab.ntt.co.jp>
Diffstat (limited to 'policy/policy.go')
-rw-r--r-- | policy/policy.go | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/policy/policy.go b/policy/policy.go index a07dbc4a..5d0c3b9a 100644 --- a/policy/policy.go +++ b/policy/policy.go @@ -1877,12 +1877,17 @@ func ActionsToApiStruct(conActions config.Actions) *api.Actions { conActions.BgpActions.SetAsPathPrepend.As, uint32(conActions.BgpActions.SetAsPathPrepend.RepeatN), } + extCommunityAction := &api.CommunityAction{ + Communities: conActions.BgpActions.SetExtCommunity.SetExtCommunityMethod.Communities, + Options: conActions.BgpActions.SetExtCommunity.Options, + } resActions := &api.Actions{ - RouteAction: action, - Community: communityAction, - Med: medAction, - AsPrepend: asprependAction, + RouteAction: action, + Community: communityAction, + Med: medAction, + AsPrepend: asprependAction, + ExtCommunity: extCommunityAction, } return resActions } |