plugin

package
v0.30.0 Latest Latest
Warning

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

Go to latest
Published: Dec 12, 2022 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CmdAdd

func CmdAdd(args *skel.CmdArgs) error

CmdAdd add handler for attaching container into network

func CmdCheck added in v0.20.0

func CmdCheck(args *skel.CmdArgs) error

CmdCheck check handler to make sure networking is as expected.

func CmdDel

func CmdDel(args *skel.CmdArgs) error

CmdDel remove handler for deleting container from network

func IPAddrToHWAddr added in v0.24.0

func IPAddrToHWAddr(ip net.IP) net.HardwareAddr

IPAddrToHWAddr takes the four octets of IPv4 address (aa.bb.cc.dd, for example) and uses them in creating a MAC address (0A:58:AA:BB:CC:DD). For IPv6, create a hash from the IPv6 string and use that for MAC Address. Assumption: the caller will ensure that an empty net.IP{} will NOT be passed. This method is copied from https://github.com/ovn-org/ovn-kubernetes/blob/master/go-controller/pkg/util/net.go

Types

type EnvArgs added in v0.4.0

type EnvArgs struct {
	cnitypes.CommonArgs
	MAC     cnitypes.UnmarshallableString `json:"mac,omitempty"`
	OvnPort cnitypes.UnmarshallableString `json:"ovnPort,omitempty"`
}

EnvArgs args containing common, desired mac and ovs port name

Jump to

Keyboard shortcuts

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