Skip to content

Commit

Permalink
update policy route nexthops para
Browse files Browse the repository at this point in the history
Signed-off-by: 马洪贞 <hzma@alauda.io>
  • Loading branch information
hongzhen-ma committed Nov 15, 2023
1 parent a54fcfe commit 7f5e68c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion pkg/controller/subnet.go
Original file line number Diff line number Diff line change
Expand Up @@ -2265,7 +2265,7 @@ func (c *Controller) addCommonRoutesForSubnet(subnet *kubeovnv1.Subnet) error {
action = kubeovnv1.PolicyRouteActionAllow
externalIDs = map[string]string{"vendor": util.CniTypeName, "subnet": subnet.Name}
)
klog.Infof("add policy route for router: %s, match %s, action %s, externalID %v", subnet.Spec.Vpc, match, action, externalIDs)
klog.Infof("add common policy route for router: %s, match %s, action %s, externalID %v", subnet.Spec.Vpc, match, action, externalIDs)
if err := c.addPolicyRouteToVpc(
subnet.Spec.Vpc,
&kubeovnv1.PolicyRoute{
Expand Down
2 changes: 1 addition & 1 deletion pkg/controller/vpc.go
Original file line number Diff line number Diff line change
Expand Up @@ -638,7 +638,7 @@ func (c *Controller) addPolicyRouteToVpc(name string, policy *kubeovnv1.PolicyRo
)

if policy.NextHopIP != "" {
nextHops = []string{policy.NextHopIP}
nextHops = strings.Split(policy.NextHopIP, ",")
}

if err = c.OVNNbClient.AddLogicalRouterPolicy(name, policy.Priority, policy.Match, string(policy.Action), nextHops, externalIDs); err != nil {
Expand Down

0 comments on commit 7f5e68c

Please sign in to comment.