Documentation ¶
Index ¶
- func ParseLinkActivationPolicy(ifindex int) (string, error)
- func ParseLinkAddressState(ifindex int) (string, error)
- func ParseLinkCarrierState(ifindex int) (string, error)
- func ParseLinkDNS(ifindex int) ([]string, error)
- func ParseLinkDomains(ifindex int) ([]string, error)
- func ParseLinkIPv4AddressState(ifindex int) (string, error)
- func ParseLinkIPv6AddressState(ifindex int) (string, error)
- func ParseLinkNTP(ifindex int) ([]string, error)
- func ParseLinkNetworkFile(ifindex int) (string, error)
- func ParseLinkOnlineState(ifindex int) (string, error)
- func ParseLinkOperationalState(ifindex int) (string, error)
- func ParseLinkSetupState(ifindex int) (string, error)
- func ParseLinkString(ifindex int, key string) (string, error)
- func ParseNetworkAddressState() (string, error)
- func ParseNetworkCarrierState() (string, error)
- func ParseNetworkDNS() ([]string, error)
- func ParseNetworkDomains() ([]string, error)
- func ParseNetworkIPv4AddressState() (string, error)
- func ParseNetworkIPv6AddressState() (string, error)
- func ParseNetworkNTP() ([]string, error)
- func ParseNetworkOnlineState() (string, error)
- func ParseNetworkOperationalState() (string, error)
- func ParseNetworkRouteDomains() ([]string, error)
- func ParseNetworkState(key string) (string, error)
- func TaskDHClient(n *network.Network, c *conf.Config) error
- func WatchDHClient(n *network.Network, c *conf.Config, finished chan bool)
- func WatchNetworkd(n *network.Network, c *conf.Config, finished chan bool) error
- type Address
- type LinkDescribe
- type LinksDescribe
- type Route
- type SDConnection
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ParseLinkAddressState ¶
func ParseLinkCarrierState ¶
func ParseLinkDNS ¶
func ParseLinkDomains ¶
func ParseLinkNTP ¶
func ParseLinkNetworkFile ¶
func ParseLinkOnlineState ¶
func ParseLinkSetupState ¶
func ParseNetworkDNS ¶
func ParseNetworkDomains ¶
func ParseNetworkNTP ¶
func ParseNetworkOnlineState ¶
func ParseNetworkState ¶
Types ¶
type Address ¶
type Address struct { IP string `json:"IP"` Family string `json:"Family"` Mask int `json:"Mask"` Label string `json:"Label"` Flags int `json:"Flags"` Scope int `json:"Scope"` Peer string `json:"Peer"` Broadcast string `json:"Broadcast"` PreferedLft int `json:"PreferedLft"` ValidLft int `json:"ValidLft"` }
type LinkDescribe ¶
type LinkDescribe struct { Index int `json:"Index"` Mtu int `json:"MTU"` TxQLen int `json:"TxQLen"` Name string `json:"Name"` AlternativeNames string `json:"AlternativeNames"` HardwareAddr string `json:"HardwareAddr"` Flags string `json:"Flags"` RawFlags uint32 `json:"RawFlags"` ParentIndex int `json:"ParentIndex"` MasterIndex int `json:"MasterIndex"` Namespace string `json:"Namespace"` Alias string `json:"Alias"` Statistics *netlink.LinkStatistics `json:"Statistics"` Promisc int `json:"Promisc"` Xdp struct { Fd int `json:"Fd"` Attached bool `json:"Attached"` Flags int `json:"Flags"` ProgID int `json:"ProgId"` } `json:"Xdp"` EncapType string `json:"EncapType"` Protinfo string `json:"Protinfo"` OperState string `json:"OperState"` NetNsID int `json:"NetNsID"` NumTxQueues int `json:"NumTxQueues"` NumRxQueues int `json:"NumRxQueues"` GSOMaxSize uint32 `json:"GSOMaxSize"` GSOMaxSegs uint32 `json:"GSOMaxSegs"` Group uint32 `json:"Group"` Slave string `json:"Slave"` KernelOperState string `json: "KernelOperState"` AddressState string `json:"AddressState"` CarrierState string `json:"CarrierState"` Driver string `json:"Driver"` IPv4AddressState string `json:"IPv4AddressState"` IPv6AddressState string `json:"IPv6AddressState"` LinkFile string `json:"LinkFile"` Model string `json:"Model"` OnlineState string `json:"OnlineState"` OperationalState string `json:"OperationalState"` Path string `json:"Path"` SetupState string `json:"SetupState"` Type string `json:"Type"` Vendor string `json:"Vendor"` ProductID string `json:"ProductID"` Manufacturer string `json:"Manufacturer"` NetworkFile string `json:"NetworkFile,omitempty"` DNS []string `json:"DNS"` Domains []string `json:"Domains"` DomainSearch []string `json:"DomainSearch"` NTP []string `json:"NTP"` Addresses []Address `json:"Address"` Routes []Route `json:"Routes"` }
type LinksDescribe ¶
type LinksDescribe struct {
Interfaces []LinkDescribe
}
type Route ¶
type Route struct { Scope int `json:"Scope"` Dst struct { IP string `json:"IP"` Mask int `json:"Mask"` } `json:"Dst"` Src string `json:"Src"` Gw string `json:"Gw"` MultiPath string `json:"MultiPath"` Protocol int `json:"Protocol"` Priority int `json:"Priority"` Table int `json:"Table"` Type int `json:"Type"` Tos int `json:"Tos"` Flags []string `json:"Flags"` MPLSDst string `json:"MPLSDst"` NewDst string `json:"NewDst"` Encap string `json:"Encap"` Mtu int `json:"MTU"` AdvMSS int `json:"AdvMSS"` Hoplimit int `json:"Hoplimit"` }
type SDConnection ¶
type SDConnection struct {
// contains filtered or unexported fields
}
func NewSDConnection ¶
func NewSDConnection() (*SDConnection, error)
func (*SDConnection) Close ¶
func (c *SDConnection) Close()
func (*SDConnection) DBusLinkDescribe ¶
func (c *SDConnection) DBusLinkDescribe(ctx context.Context) (*LinksDescribe, error)
func (*SDConnection) DBusNetworkReconfigureLink ¶
func (c *SDConnection) DBusNetworkReconfigureLink(ctx context.Context, index int) error
func (*SDConnection) DBusNetworkReload ¶
func (c *SDConnection) DBusNetworkReload(ctx context.Context) error
Click to show internal directories.
Click to hide internal directories.