dockercli

package
v0.13.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 25, 2024 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Overview

Source: https://github.com/docker/cli/blob/v25.0.1/opts/mount.go

Apache License 2.0, https://github.com/docker/cli/blob/master/LICENSE

Removed: logrus dependency

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MountOpt

type MountOpt struct {
	// contains filtered or unexported fields
}

MountOpt is a Value type for parsing mounts

func (*MountOpt) Set

func (m *MountOpt) Set(value string) error

Set a new mount value

func (*MountOpt) String

func (m *MountOpt) String() string

String returns a string repr of this option

func (*MountOpt) Type

func (m *MountOpt) Type() string

Type returns the type of this option

func (*MountOpt) Value

func (m *MountOpt) Value() []mounttypes.Mount

Value returns the mounts

type NetworkAttachmentOpts

type NetworkAttachmentOpts struct {
	Target       string
	Aliases      []string
	DriverOpts   map[string]string
	Links        []string // TODO add support for links in the csv notation of `--network`
	IPv4Address  string
	IPv6Address  string
	LinkLocalIPs []string
	MacAddress   string
}

NetworkAttachmentOpts represents the network options for endpoint creation

type NetworkOpt

type NetworkOpt struct {
	// contains filtered or unexported fields
}

NetworkOpt represents a network config in swarm mode.

func (*NetworkOpt) NetworkMode

func (n *NetworkOpt) NetworkMode() string

NetworkMode return the network mode for the network option

func (*NetworkOpt) Set

func (n *NetworkOpt) Set(value string) error

Set networkopts value

func (*NetworkOpt) String

func (n *NetworkOpt) String() string

String returns the network opts as a string

func (*NetworkOpt) Type

func (n *NetworkOpt) Type() string

Type returns the type of this option

func (*NetworkOpt) Value

func (n *NetworkOpt) Value() []NetworkAttachmentOpts

Value returns the networkopts

type ServiceVolumeBind

type ServiceVolumeBind struct {
	Propagation string `yaml:",omitempty" json:"propagation,omitempty"`
}

ServiceVolumeBind are options for a service volume of type bind

type ServiceVolumeCluster

type ServiceVolumeCluster struct{}

ServiceVolumeCluster are options for a service volume of type cluster. Deliberately left blank for future options, but unused now.

type ServiceVolumeConfig

type ServiceVolumeConfig struct {
	Type        string                `yaml:",omitempty" json:"type,omitempty"`
	Source      string                `yaml:",omitempty" json:"source,omitempty"`
	Target      string                `yaml:",omitempty" json:"target,omitempty"`
	ReadOnly    bool                  `mapstructure:"read_only" yaml:"read_only,omitempty" json:"read_only,omitempty"`
	Consistency string                `yaml:",omitempty" json:"consistency,omitempty"`
	Bind        *ServiceVolumeBind    `yaml:",omitempty" json:"bind,omitempty"`
	Volume      *ServiceVolumeVolume  `yaml:",omitempty" json:"volume,omitempty"`
	Tmpfs       *ServiceVolumeTmpfs   `yaml:",omitempty" json:"tmpfs,omitempty"`
	Cluster     *ServiceVolumeCluster `yaml:",omitempty" json:"cluster,omitempty"`
}

ServiceVolumeConfig are references to a volume used by a service

func ParseVolume

func ParseVolume(spec string) (ServiceVolumeConfig, error)

ParseVolume parses a volume spec without any knowledge of the target platform

type ServiceVolumeTmpfs

type ServiceVolumeTmpfs struct {
	Size int64 `yaml:",omitempty" json:"size,omitempty"`
}

ServiceVolumeTmpfs are options for a service volume of type tmpfs

type ServiceVolumeVolume

type ServiceVolumeVolume struct {
	NoCopy bool `mapstructure:"nocopy" yaml:"nocopy,omitempty" json:"nocopy,omitempty"`
}

ServiceVolumeVolume are options for a service volume of type volume

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL