Documentation ¶
Index ¶
- Constants
- func GenerateIPAM(driver string, subnetStr, gatewayStr, ipRangeStr string, ...) (map[string]interface{}, error)
- func GetBridgeName(id int) string
- func ParseMTU(mtu string) (int, error)
- type CNIEnv
- func (e *CNIEnv) AcquireNextID() (int, error)
- func (e *CNIEnv) GenerateCNIPlugins(driver string, id int, name string, ipam map[string]interface{}, ...) ([]CNIPlugin, error)
- func (e *CNIEnv) GenerateNetworkConfig(labels []string, id int, name string, plugins []CNIPlugin) (*networkConfig, error)
- func (e *CNIEnv) NetworkMap() map[string]*networkConfig
- func (e *CNIEnv) WriteNetworkConfig(net *networkConfig) error
- type CNIPlugin
- type IPAMRange
- type IPAMRoute
Constants ¶
View Source
const ( DefaultNetworkName = "bridge" DefaultID = 0 DefaultCIDR = "10.4.0.0/24" DefaultIPAMDriver = "host-local" )
Variables ¶
This section is empty.
Functions ¶
func GenerateIPAM ¶ added in v0.16.0
func GetBridgeName ¶ added in v0.16.0
Types ¶
type CNIEnv ¶
func (*CNIEnv) AcquireNextID ¶ added in v0.18.0
AcquireNextID suggests the next ID.
func (*CNIEnv) GenerateCNIPlugins ¶ added in v0.18.0
func (*CNIEnv) GenerateNetworkConfig ¶ added in v0.18.0
func (e *CNIEnv) GenerateNetworkConfig(labels []string, id int, name string, plugins []CNIPlugin) (*networkConfig, error)
GenerateNetworkConfig creates networkConfig. GenerateNetworkConfig does not fill "File" field.
func (*CNIEnv) NetworkMap ¶ added in v0.18.0
func (*CNIEnv) WriteNetworkConfig ¶ added in v0.18.0
WriteNetworkConfig writes networkConfig file to cni config path.
Click to show internal directories.
Click to hide internal directories.