Versions in this module Expand all Collapse all v1 v1.13.1 Feb 8, 2017 Changes in this version + var ErrNoSwarm = fmt.Errorf("This node is not part of a swarm") + var ErrPendingSwarmExists = fmt.Errorf(...) + var ErrSwarmCertificatesExpired = errors.New(...) + var ErrSwarmExists = fmt.Errorf(...) + var ErrSwarmJoinTimeoutReached = fmt.Errorf(...) + var ErrSwarmLocked = fmt.Errorf(...) + type Cluster struct + func New(config Config) (*Cluster, error) + func (c *Cluster) AttachNetwork(target string, containerID string, addresses []string) (*network.NetworkingConfig, error) + func (c *Cluster) Cleanup() + func (c *Cluster) CreateNetwork(s apitypes.NetworkCreateRequest) (string, error) + func (c *Cluster) CreateSecret(s types.SecretSpec) (string, error) + func (c *Cluster) CreateService(s types.ServiceSpec, encodedAuth string) (*apitypes.ServiceCreateResponse, error) + func (c *Cluster) DetachNetwork(target string, containerID string) error + func (c *Cluster) GetAdvertiseAddress() string + func (c *Cluster) GetListenAddress() string + func (c *Cluster) GetLocalAddress() string + func (c *Cluster) GetNetwork(input string) (apitypes.NetworkResource, error) + func (c *Cluster) GetNetworks() ([]apitypes.NetworkResource, error) + func (c *Cluster) GetNetworksByName(name string) ([]apitypes.NetworkResource, error) + func (c *Cluster) GetNode(input string) (types.Node, error) + func (c *Cluster) GetNodes(options apitypes.NodeListOptions) ([]types.Node, error) + func (c *Cluster) GetRemoteAddress() string + func (c *Cluster) GetSecret(id string) (types.Secret, error) + func (c *Cluster) GetSecrets(options apitypes.SecretListOptions) ([]types.Secret, error) + func (c *Cluster) GetService(input string) (types.Service, error) + func (c *Cluster) GetServices(options apitypes.ServiceListOptions) ([]types.Service, error) + func (c *Cluster) GetTask(input string) (types.Task, error) + func (c *Cluster) GetTasks(options apitypes.TaskListOptions) ([]types.Task, error) + func (c *Cluster) GetUnlockKey() (string, error) + func (c *Cluster) Info() types.Info + func (c *Cluster) Init(req types.InitRequest) (string, error) + func (c *Cluster) Inspect() (types.Swarm, error) + func (c *Cluster) IsAgent() bool + func (c *Cluster) IsManager() bool + func (c *Cluster) Join(req types.JoinRequest) error + func (c *Cluster) Leave(force bool) error + func (c *Cluster) ListenClusterEvents() <-chan struct{} + func (c *Cluster) RemoveNetwork(input string) error + func (c *Cluster) RemoveNode(input string, force bool) error + func (c *Cluster) RemoveSecret(id string) error + func (c *Cluster) RemoveService(input string) error + func (c *Cluster) ServiceLogs(ctx context.Context, input string, config *backend.ContainerLogsConfig, ...) error + func (c *Cluster) UnlockSwarm(req types.UnlockRequest) error + func (c *Cluster) Update(version uint64, spec types.Spec, flags types.UpdateFlags) error + func (c *Cluster) UpdateAttachment(target, containerID string, config *network.NetworkingConfig) error + func (c *Cluster) UpdateNode(input string, version uint64, spec types.NodeSpec) error + func (c *Cluster) UpdateSecret(id string, version uint64, spec types.SecretSpec) error + func (c *Cluster) UpdateService(serviceIDOrName string, version uint64, spec types.ServiceSpec, ...) (*apitypes.ServiceUpdateResponse, error) + func (c *Cluster) WaitForDetachment(ctx context.Context, networkName, networkID, taskID, containerID string) error + type Config struct + Backend executorpkg.Backend + DefaultAdvertiseAddr string + Name string + NetworkSubnetsProvider NetworkSubnetsProvider + Root string + RuntimeRoot string + type NetworkSubnetsProvider interface + V4Subnets func() []net.IPNet + V6Subnets func() []net.IPNet