Documentation ¶
Index ¶
- func CloseOvsInstance(prjID string) error
- type OvsNode
- func (o *OvsNode) AddInterface(ifName string, ifIndex int, ns netns.NsHandle) error
- func (o *OvsNode) CanRunConsole() error
- func (o *OvsNode) Capture(ifIndex int, out io.Writer) error
- func (o *OvsNode) Close() error
- func (o *OvsNode) Console(shell bool, in io.ReadCloser, out io.Writer, resizeCh chan term.Winsize) error
- func (o *OvsNode) CopyFrom(srcPath, destPath string) error
- func (o *OvsNode) CopyTo(srcPath, destPath string) error
- func (o *OvsNode) GetBridgeName() string
- func (o *OvsNode) GetInterfaceName(ifIndex int) string
- func (o *OvsNode) GetInterfacesState() map[string]link.IfState
- func (s *OvsNode) GetName() string
- func (o *OvsNode) GetNetns() (netns.NsHandle, error)
- func (s *OvsNode) GetShortName() string
- func (s *OvsNode) GetType() string
- func (o *OvsNode) IsRunning() bool
- func (o *OvsNode) LoadConfig(confPath string) ([]string, error)
- func (o *OvsNode) ReadConfigFiles(confDir string) (map[string][]byte, error)
- func (o *OvsNode) Save(dstPath string) error
- func (n *OvsNode) SetInterfaceState(ifIndex int, state link.IfState) error
- func (o *OvsNode) Start() error
- func (o *OvsNode) Stop() error
- type OvsProjectInstance
- func (o *OvsProjectInstance) AddBr(brName string) error
- func (o *OvsProjectInstance) AddPort(brName, ifName string) error
- func (o *OvsProjectInstance) Capture(ifName string, out io.Writer) error
- func (o *OvsProjectInstance) Close() error
- func (o *OvsProjectInstance) DelBr(brName string) error
- func (o *OvsProjectInstance) DelPort(brName, ifName string) error
- func (o *OvsProjectInstance) Exec(cmd []string) error
- func (o *OvsProjectInstance) GetNetns() (netns.NsHandle, error)
- func (o *OvsProjectInstance) LoadConfig(name, brName, confPath string) ([]string, error)
- func (o *OvsProjectInstance) SaveConfig(name, brName, dstPath string) error
- func (o *OvsProjectInstance) Start() error
- type State
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CloseOvsInstance ¶
Types ¶
type OvsNode ¶
type OvsNode struct { PrjID string Name string ShortName string Running bool OvsInstance *OvsProjectInstance Interfaces map[string]link.IfState Logger *logrus.Entry }
func NewOvsNode ¶
func (*OvsNode) AddInterface ¶
func (*OvsNode) CanRunConsole ¶
func (*OvsNode) GetBridgeName ¶ added in v0.1.1
func (*OvsNode) GetInterfaceName ¶
func (*OvsNode) GetInterfacesState ¶ added in v0.1.1
func (*OvsNode) GetShortName ¶ added in v0.1.1
func (*OvsNode) ReadConfigFiles ¶ added in v0.2.0
func (*OvsNode) SetInterfaceState ¶
type OvsProjectInstance ¶
func GetOvsInstance ¶
func GetOvsInstance(prjID string) *OvsProjectInstance
func NewOvsInstance ¶
func NewOvsInstance(prjID string) (*OvsProjectInstance, error)
func (*OvsProjectInstance) AddBr ¶
func (o *OvsProjectInstance) AddBr(brName string) error
func (*OvsProjectInstance) AddPort ¶
func (o *OvsProjectInstance) AddPort(brName, ifName string) error
func (*OvsProjectInstance) Capture ¶
func (o *OvsProjectInstance) Capture(ifName string, out io.Writer) error
func (*OvsProjectInstance) Close ¶
func (o *OvsProjectInstance) Close() error
func (*OvsProjectInstance) DelBr ¶
func (o *OvsProjectInstance) DelBr(brName string) error
func (*OvsProjectInstance) DelPort ¶
func (o *OvsProjectInstance) DelPort(brName, ifName string) error
func (*OvsProjectInstance) Exec ¶
func (o *OvsProjectInstance) Exec(cmd []string) error
func (*OvsProjectInstance) GetNetns ¶
func (o *OvsProjectInstance) GetNetns() (netns.NsHandle, error)
func (*OvsProjectInstance) LoadConfig ¶
func (o *OvsProjectInstance) LoadConfig(name, brName, confPath string) ([]string, error)
func (*OvsProjectInstance) SaveConfig ¶
func (o *OvsProjectInstance) SaveConfig(name, brName, dstPath string) error
func (*OvsProjectInstance) Start ¶
func (o *OvsProjectInstance) Start() error
Click to show internal directories.
Click to hide internal directories.