Documentation
¶
Index ¶
Constants ¶
View Source
const ( // CNIBinDir is the default path to CNI plugin binaries. CNIBinDir = "/opt/cni/bin" // CNIConfDir is the default path to CNI network configuration files. CNIConfDir = "/etc/cni/net.d" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Manager ¶
Manager contains network manager configuration and exposes methods to bring up and down network interface.
func (*Manager) SetPodCIDR ¶
SetPodCIDR updates pod's CIDR.
func (*Manager) SetUpPod ¶
func (m *Manager) SetUpPod(podConfig *PodConfig) (*PodNetwork, error)
SetUpPod bring up pod's network interface.
func (*Manager) TearDownPod ¶
func (m *Manager) TearDownPod(podNetwork *PodNetwork) error
TearDownPod tears down pod's network interface.
type PodConfig ¶
type PodConfig struct {
ID string
Namespace string
Name string
NsPath string
PortMappings []*k8s.PortMapping
}
PodConfig contains/defines pod network configuration.
type PodNetwork ¶
type PodNetwork struct {
// contains filtered or unexported fields
}
PodNetwork represents set up pod's network. It is a caller's responsibility to tear this network down by calling Manager.TearDownPod during pod's shutdown. PodNetwork is also used to retrieve pod's IP address.
Click to show internal directories.
Click to hide internal directories.