package windows

import "github.com/docker/docker/libnetwork/drivers/windows"

Index

Constants

const (
	// NetworkName label for bridge driver
	NetworkName = "com.docker.network.windowsshim.networkname"

	// HNSID of the discovered network
	HNSID = "com.docker.network.windowsshim.hnsid"

	// RoutingDomain of the network
	RoutingDomain = "com.docker.network.windowsshim.routingdomain"

	// Interface of the network
	Interface = "com.docker.network.windowsshim.interface"

	// QosPolicies of the endpoint
	QosPolicies = "com.docker.endpoint.windowsshim.qospolicies"

	// VLAN of the network
	VLAN = "com.docker.network.windowsshim.vlanid"

	// VSID of the network
	VSID = "com.docker.network.windowsshim.vsid"

	// DNSSuffix of the network
	DNSSuffix = "com.docker.network.windowsshim.dnssuffix"

	// DNSServers of the network
	DNSServers = "com.docker.network.windowsshim.dnsservers"

	// MacPool of the network
	MacPool = "com.docker.network.windowsshim.macpool"

	// SourceMac of the network
	SourceMac = "com.docker.network.windowsshim.sourcemac"

	// DisableICC label
	DisableICC = "com.docker.network.windowsshim.disableicc"

	// DisableDNS label
	DisableDNS = "com.docker.network.windowsshim.disable_dns"

	// DisableGatewayDNS label
	DisableGatewayDNS = "com.docker.network.windowsshim.disable_gatewaydns"

	// EnableOutboundNat label
	EnableOutboundNat = "com.docker.network.windowsshim.enable_outboundnat"

	// OutboundNatExceptions label
	OutboundNatExceptions = "com.docker.network.windowsshim.outboundnat_exceptions"
)

Functions

func AllocatePorts

func AllocatePorts(portMapper *portmapper.PortMapper, bindings []types.PortBinding, containerIP net.IP) ([]types.PortBinding, error)

AllocatePorts allocates ports specified in bindings from the portMapper

func ConvertPortBindings

func ConvertPortBindings(portBindings []types.PortBinding) ([]json.RawMessage, error)

ConvertPortBindings converts PortBindings to JSON for HNS request

func IsBuiltinLocalDriver

func IsBuiltinLocalDriver(networkType string) bool

IsBuiltinLocalDriver validates if network-type is a builtin local-scoped driver

func ParsePortBindingPolicies

func ParsePortBindingPolicies(policies []json.RawMessage) ([]types.PortBinding, error)

ParsePortBindingPolicies parses HNS endpoint response message to PortBindings

func RegisterBuiltinLocalDrivers

func RegisterBuiltinLocalDrivers(r driverapi.Registerer, driverConfig func(string) map[string]interface{}) error

GetInit returns an initializer for the given network type

func ReleasePorts

func ReleasePorts(portMapper *portmapper.PortMapper, bindings []types.PortBinding) error

ReleasePorts releases ports specified in bindings from the portMapper

Types

type EndpointConnectivity

type EndpointConnectivity struct {
	PortBindings []types.PortBinding
	ExposedPorts []types.TransportPort
}

EndpointConnectivity stores the port bindings and exposed ports that the user has specified in epOptions.

func ParseEndpointConnectivity

func ParseEndpointConnectivity(epOptions map[string]interface{}) (*EndpointConnectivity, error)

ParseEndpointConnectivity parses options passed to CreateEndpoint, specifically port bindings, and store in a endpointConnectivity object.

type ErrUnsupportedAddressType

type ErrUnsupportedAddressType string

ErrUnsupportedAddressType is returned when the specified address type is not supported.

func (ErrUnsupportedAddressType) Error

func (uat ErrUnsupportedAddressType) Error() string

Source Files

labels.go port_mapping.go windows.go windows_store.go

Directories

PathSynopsis
libnetwork/drivers/windows/overlayPackage overlay is a generated protocol buffer package.
Version
v26.0.0-rc2+incompatible
Published
Mar 7, 2024
Platform
windows/amd64
Imports
18 packages
Last checked
3 hours ago

Tools for package owners.