cniconf

package
v1.9.6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 9, 2024 License: Apache-2.0 Imports: 27 Imported by: 0

Documentation

Index

Constants

View Source
const (
	IPAMServiceNamespace    = "kube-system"
	IPAMServiceName         = "cce-eni-ipam"
	CCETemplateFileBasePath = "/etc/kubernetes/cni/"
	DefaultMTU              = 1500
)

Variables

View Source
var (
	CCETemplateFilePathMap = map[types.ContainerNetworkMode]string{

		types.CCEModeRouteVeth:   CCETemplateFileBasePath + "cce-vpc-route-veth.tmpl",
		types.CCEModeRouteIPVlan: CCETemplateFileBasePath + "cce-vpc-route-ipvlan.tmpl",

		types.CCEModeSecondaryIPVeth:   CCETemplateFileBasePath + "cce-cni-secondary-ip-veth.tmpl",
		types.CCEModeSecondaryIPIPVlan: CCETemplateFileBasePath + "cce-cni-secondary-ip-ipvlan.tmpl",

		types.CCEModeBBCSecondaryIPVeth:   CCETemplateFileBasePath + "cce-cni-bbc-secondary-ip-veth.tmpl",
		types.CCEModeBBCSecondaryIPIPVlan: CCETemplateFileBasePath + "cce-cni-bbc-secondary-ip-ipvlan.tmpl",

		types.CCEModeCrossVPCEni:          CCETemplateFileBasePath + "cce-cross-vpc-eni.tmpl",
		types.CCEModeExclusiveCrossVPCEni: CCETemplateFileBasePath + "cce-exclusive-cross-vpc-eni.tmpl",
	}
)

Functions

This section is empty.

Types

type CNIConfigData

type CNIConfigData struct {
	// NetworkName is the network name in cni config file
	NetworkName string
	// IPAMEndPoint is the ipam endpoint. etc 127.0.0.1:50050
	IPAMEndPoint string

	VethMTU         int
	MasterInterface string
	LocalDNSAddress string
	InstanceType    string

	// Subnet is node PodCIDR for vpc route mode
	Subnet string

	// HostLocalRange is host-local plugin RangeSet
	HostLocalRange hostlocal.RangeSet
}

CNIConfigData contains everything a cni config needs

type Controller

type Controller struct {
	// contains filtered or unexported fields
}

Controller updates cni config file on the node

func (*Controller) ReconcileCNIConfig

func (c *Controller) ReconcileCNIConfig()

func (*Controller) SyncNode

func (c *Controller) SyncNode(nodeKey string, _ corelisters.NodeLister) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL