cfgsyslib

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Mar 15, 2019 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	SYSCTL_CONF_PATH = "/etc/sysctl.d/30-beluganos.conf"
	SYSCTL_WAIT_SEC  = 1 * time.Second
)
View Source
const NETPLAN_CMD = "netplan+"
View Source
const NETPLAN_CONF_PATH = "/etc/netplan/02-beluganos.yaml"
View Source
const NETPLAN_WAIT_SEC = 1 * time.Second
View Source
const (
	VRF_CONF_PATH = "/etc/vrf.conf"
)

Variables

This section is empty.

Functions

func BackupNetwotkRun

func BackupNetwotkRun(path, backup string, client api.RpcApiClient) (*api.ExecuteReply, error)

func BackupSysctlRun

func BackupSysctlRun(path, backup string, client api.RpcApiClient) (*api.ExecuteReply, error)

func BackupVrfExec

func BackupVrfExec(path, backup string, client api.RpcApiClient) (*api.ExecuteReply, error)

func CommitNetworkRun

func CommitNetworkRun(backup string, wait time.Duration, client api.RpcApiClient) (*api.ExecuteReply, error)

func CommitSysctlRun

func CommitSysctlRun(path, backup string, wait time.Duration, client api.RpcApiClient) (*api.ExecuteReply, error)

func CommitVrfExec

func CommitVrfExec(backup string, client api.RpcApiClient) (*api.ExecuteReply, error)

func DelNetworkRun

func DelNetworkRun(device string, vid uint, mtu uint, addrs []string, client api.RpcApiClient) (*api.ExecuteReply, error)

func DoNetworkRun

func DoNetworkRun(cmd string, device string, vid uint, mtu uint, addrs []string, client api.RpcApiClient) (*api.ExecuteReply, error)

func DoSysctlRun

func DoSysctlRun(cmd string, args []string, client api.RpcApiClient) (*api.ExecuteReply, error)

func DoVrfExec

func DoVrfExec(cmd string, args []string, client api.RpcApiClient) (*api.ExecuteReply, error)

func LoadNetworkRun

func LoadNetworkRun(wait time.Duration, client api.RpcApiClient) (*api.ExecuteReply, error)

func LoadSysctlRun

func LoadSysctlRun(path string, wait time.Duration, client api.RpcApiClient) (*api.ExecuteReply, error)

func LoadVrfExec

func LoadVrfExec(client api.RpcApiClient) (*api.ExecuteReply, error)

func NetworkBackupPath

func NetworkBackupPath(path string) string

func RollbackNetworkRun

func RollbackNetworkRun(backup, path string, client api.RpcApiClient) (*api.ExecuteReply, error)

func RollbackSysctlRun

func RollbackSysctlRun(backup, path string, client api.RpcApiClient) (*api.ExecuteReply, error)

func RollbackVrfExec

func RollbackVrfExec(backup, path string, client api.RpcApiClient) (*api.ExecuteReply, error)

func SetNetworkRun

func SetNetworkRun(device string, vid uint, mtu uint, addrs []string, client api.RpcApiClient) (*api.ExecuteReply, error)

func SysctlBackupPath

func SysctlBackupPath(path string) string

func SystemctlRun

func SystemctlRun(params []string, client api.RpcApiClient) (*api.ExecuteReply, error)

func VrfBackupPath

func VrfBackupPath(path string) string

Types

type NetowrkAddrs

type NetowrkAddrs []*net.IPNet

func (*NetowrkAddrs) Set

func (n *NetowrkAddrs) Set(value string) error

func (NetowrkAddrs) String

func (n NetowrkAddrs) String() string

func (NetowrkAddrs) Strings

func (n NetowrkAddrs) Strings() []string

func (NetowrkAddrs) Type

func (n NetowrkAddrs) Type() string

type NetworkSlaves

type NetworkSlaves []string

func (*NetworkSlaves) Set

func (n *NetworkSlaves) Set(value string) error

func (NetworkSlaves) String

func (n NetworkSlaves) String() string

Jump to

Keyboard shortcuts

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