package
1.0.5
Repository: https://github.com/fgschwan/vpp-agent.git
Documentation: pkg.go.dev

# Functions

AddInterfaceIP calls AddrAdd Netlink API.
AddVethInterface calls LinkAdd Netlink API for the Netlink.Veth interface type.
CompareNamespaces is a comparison function for "intf.Interfaces_Interface_Namespace" type.
CreateNamedNetNs creates a new named Linux network namespace.
DeleteNamedNetNs deletes an existing named Linux network namespace.
DelInterfaceIP calls AddrDel Netlink API.
DelVethInterface calls LinkDel Netlink API for the Netlink.Veth interface type.
GetDefaultNamespace returns an instance of the proto message referencing default namespace.
GetInterfaceType returns the type (string representation) of a given interface.
GetOrCreateNs returns an existing Linux network namespace or creates a new one if it doesn't exist yet.
GetVethPeerName return the peer name for a given VETH interface.
InterfaceAdminDown calls Netlink API LinkSetDown.
InterfaceAdminUp calls Netlink API LinkSetUp.
InterfaceExists checks if interface with a given name exists.
NamespaceToStr returns a string representation of a namespace suitable for logging purposes.
NewNamespaceMgmtCtx creates and returns a new context for management of Linux namespaces.
SetInterfaceMac calls LinkSetHardwareAddr netlink API.
SetInterfaceMTU calls LinkSetMTU Netlink API.
SetInterfaceNamespace moves a given Linux interface into a specified namespace.
SwitchNamespace switches the network namespace of the current thread.

# Structs

NamespaceMgmtCtx represents context of an ongoing management of Linux namespaces.