Documentation ¶
Index ¶
- Constants
- Variables
- type Client
- func (c *Client) AddPeerCIDRRoute(peerPodCIDR *net.IPNet, gwLinkIdx int, peerNodeIP, peerGwIP net.IP) ([]*netlink.Route, error)
- func (c *Client) DeletePeerCIDRRoute(routes []*netlink.Route) error
- func (c *Client) Initialize(nodeConfig *config.NodeConfig) error
- func (c *Client) ListPeerCIDRRoute() (map[string][]*netlink.Route, error)
- func (c *Client) RemoveServiceRouting() error
Constants ¶
View Source
const ( // AntreaServiceTable is route table name for Antrea service traffic. AntreaServiceTable = "Antrea-service" // AntreaServiceTableIdx is route table index for Antrea service traffic. AntreaServiceTableIdx = 300 // AntreaIPRulePriority is Antrea IP rule priority AntreaIPRulePriority = 300 )
Variables ¶
View Source
var (
// ServiceRtTable contains Antrea service route table information.
ServiceRtTable = &serviceRtTableConfig{Idx: 254, Name: "main"}
)
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client is route client.
func NewClient ¶
func NewClient(encapMode config.TrafficEncapModeType) *Client
NewClient returns a route client
func (*Client) AddPeerCIDRRoute ¶
func (c *Client) AddPeerCIDRRoute(peerPodCIDR *net.IPNet, gwLinkIdx int, peerNodeIP, peerGwIP net.IP) ([]*netlink.Route, error)
AddPeerCIDRRoute adds routes to route tables for Antrea use.
func (*Client) DeletePeerCIDRRoute ¶
DeletePeerCIDRRoute deletes routes.
func (*Client) Initialize ¶
func (c *Client) Initialize(nodeConfig *config.NodeConfig) error
Initialize sets up route tables for Antrea.
func (*Client) ListPeerCIDRRoute ¶
ListPeerCIDRRoute returns list of routes from peer and local CIDRs
func (*Client) RemoveServiceRouting ¶
RemoveServiceRouting removes service routing setup.
Click to show internal directories.
Click to hide internal directories.