types

package
v0.0.0-...-7519094 Latest Latest
Warning

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

Go to latest
Published: Jan 13, 2021 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Manager

type Manager interface {
	CreateIpoibLink(conf *NetConf, ifName string, netns ns.NetNS) (*current.Interface, error)
	RemoveIpoibLink(ifName string, netns ns.NetNS) error
}

Manager provides interface invoke ipoib nic related operations

type NetConf

type NetConf struct {
	types.NetConf
	Master string `json:"master"`
	IPMasq bool   `json:"ipMasq"`
}

NetConf extends cni NetConf

type NetlinkManager

type NetlinkManager interface {
	LinkByName(string) (netlink.Link, error)
	LinkSetUp(netlink.Link) error
	LinkSetDown(netlink.Link) error
	LinkSetName(netlink.Link, string) error
	LinkSetNsFd(netlink.Link, int) error
	LinkAdd(link netlink.Link) error
	LinkDel(link netlink.Link) error
	SetSysVal(attribute, value string) (string, error)
}

NetlinkManager is an interface to mock nelink library

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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