Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ConfigReference ¶
type ConfigReference struct {
Network string
}
ConfigReference specifies the source which provides a network's configuration
type EndpointIPAMConfig ¶
type EndpointIPAMConfig struct { IPv4Address string `json:",omitempty"` IPv6Address string `json:",omitempty"` LinkLocalIPs []string `json:",omitempty"` }
EndpointIPAMConfig represents IPAM configurations for the endpoint
func (*EndpointIPAMConfig) Copy ¶
func (cfg *EndpointIPAMConfig) Copy() *EndpointIPAMConfig
Copy makes a copy of the endpoint ipam config
type EndpointResource ¶
type EndpointResource struct { Name string EndpointID string MacAddress string IPv4Address string IPv6Address string }
EndpointResource contains network resources allocated and used for a container in a network.
type EndpointSettings ¶
type EndpointSettings struct { // Configurations IPAMConfig *EndpointIPAMConfig Links []string Aliases []string // Aliases holds the list of extra, user-specified DNS names for this endpoint. // MacAddress may be used to specify a MAC address when the container is created. // Once the container is running, it becomes operational data (it may contain a // generated address). MacAddress string DriverOpts map[string]string // Operational data NetworkID string EndpointID string Gateway string IPAddress string IPPrefixLen int IPv6Gateway string GlobalIPv6Address string GlobalIPv6PrefixLen int // DNSNames holds all the (non fully qualified) DNS names associated to this endpoint. First entry is used to // generate PTR records. DNSNames []string }
EndpointSettings stores the network endpoint details
func (*EndpointSettings) Copy ¶
func (es *EndpointSettings) Copy() *EndpointSettings
Copy makes a deep copy of `EndpointSettings`
type IPAM ¶
type IPAM struct { Driver string Options map[string]string // Per network IPAM driver options Config []IPAMConfig }
IPAM represents IP Address Management
type IPAMConfig ¶
type IPAMConfig struct { Subnet string `json:",omitempty"` IPRange string `json:",omitempty"` Gateway string `json:",omitempty"` AuxAddress map[string]string `json:"AuxiliaryAddresses,omitempty"` }
IPAMConfig represents IPAM configurations
type Network ¶
type Network struct { Name string // Name is the name of the network ID string `json:"Id"` // ID uniquely identifies a network on a single machine Created time.Time // Created is the time the network created Scope string // Scope describes the level at which the network exists (e.g. `swarm` for cluster-wide or `local` for machine level) Driver string // Driver is the Driver name used to create the network (e.g. `bridge`, `overlay`) EnableIPv6 bool // EnableIPv6 represents whether to enable IPv6 IPAM IPAM // IPAM is the network's IP Address Management Internal bool // Internal represents if the network is used internal only Attachable bool // Attachable represents if the global scope is manually attachable by regular containers from workers in swarm mode. Ingress bool // Ingress indicates the network is providing the routing-mesh for the swarm cluster. ConfigFrom ConfigReference // ConfigFrom specifies the source which will provide the configuration for this network. ConfigOnly bool // ConfigOnly networks are place-holder networks for network configurations to be used by other networks. ConfigOnly networks cannot be used directly to run containers or services. Containers map[string]EndpointResource // Containers contains endpoints belonging to the network Options map[string]string // Options holds the network specific options to use for when creating the network Labels map[string]string // Labels holds metadata specific to the network being created Peers []PeerInfo `json:",omitempty"` // List of peer nodes for an overlay network Services map[string]ServiceInfo `json:",omitempty"` }
Network is the body of the "get network" http response message.
type NetworkSubnet ¶
type NetworkSubnet interface { // Contains checks whether the NetworkSubnet contains [addr]. Contains(addr net.IP) bool // IsStatic checks whether the subnet was statically allocated (ie. user-defined). IsStatic() bool }
NetworkSubnet describes a user-defined subnet for a specific network. It's only used to validate if an EndpointIPAMConfig is valid for a specific network.
type ServiceInfo ¶
ServiceInfo represents service parameters with the list of service's tasks