Documentation
¶
Index ¶
Constants ¶
View Source
const ImplementedSpecVersion string = "0.4.0"
Variables ¶
View Source
var SupportedVersions = []string{"0.3.0", "0.3.1", ImplementedSpecVersion}
Functions ¶
Types ¶
type IPConfig ¶
type IPConfig struct {
// IP version, either "4" or "6"
Version string
// Index into Result structs Interfaces list
Interface *int
Address net.IPNet
Gateway net.IP
}
IPConfig contains values necessary to configure an IP address on an interface
func (*IPConfig) MarshalJSON ¶
func (*IPConfig) UnmarshalJSON ¶
type Interface ¶
type Interface struct {
Name string `json:"name"`
Mac string `json:"mac,omitempty"`
Sandbox string `json:"sandbox,omitempty"`
}
Interface contains values about the created interfaces
type Result ¶
type Result struct {
CNIVersion string `json:"cniVersion,omitempty"`
Interfaces []*Interface `json:"interfaces,omitempty"`
IPs []*IPConfig `json:"ips,omitempty"`
Routes []*types.Route `json:"routes,omitempty"`
DNS types.DNS `json:"dns,omitempty"`
}
Result is what gets returned from the plugin (via stdout) to the caller
Click to show internal directories.
Click to hide internal directories.