container

package
v0.0.0-...-f4cebfc Latest Latest
Warning

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

Go to latest
Published: Feb 22, 2020 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Overview

Package container is a generated protocol buffer package.

It is generated from these files:

pb/moby/container/container.proto

It has these top-level messages:

HealthConfig
Config
ContainerCreateCreatedBody
DeviceMapping
RestartPolicy
LogConfig
Resources
HostConfig

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrNilPointer        = errors.New("found nil pointer")
	ErrConfigIsNil       = errors.New("Config is nil")
	ErrImageNotSpecified = errors.New("Config's filed (Image) not specified")
	ErrHostConfigIsNil   = errors.New("HostConfig is nil")
)

Functions

This section is empty.

Types

type Config

type Config struct {
	// Hostname string // Hostname
	Hostname string `protobuf:"bytes,1,opt,name=hostname,proto3" json:"hostname,omitempty"`
	// Domainname string // Domainname
	Domainname string `protobuf:"bytes,2,opt,name=domainname,proto3" json:"domainname,omitempty"`
	// User string // User that will run the command(s) inside the container, also support user:group
	User string `protobuf:"bytes,3,opt,name=user,proto3" json:"user,omitempty"`
	// AttachStdin bool // Attach the standard input, makes possible user interaction
	AttachStdin bool `protobuf:"varint,4,opt,name=attach_stdin,json=attachStdin,proto3" json:"attach_stdin,omitempty"`
	// AttachStdout bool // Attach the standard output
	AttachStdout bool `protobuf:"varint,5,opt,name=attach_stdout,json=attachStdout,proto3" json:"attach_stdout,omitempty"`
	// AttachStderr bool // Attach the standard error
	AttachStderr bool `protobuf:"varint,6,opt,name=attach_stderr,json=attachStderr,proto3" json:"attach_stderr,omitempty"`
	// ExposedPorts nat.PortSet `json",omitempty"` // List of exposed ports
	ExposedPorts *nat.PortSet `protobuf:"bytes,7,opt,name=exposed_ports,json=exposedPorts" json:"exposed_ports,omitempty"`
	// Tty bool // Attach standard streams to a tty, including stdin if it is not closed.
	Tty bool `protobuf:"varint,8,opt,name=tty,proto3" json:"tty,omitempty"`
	// OpenStdin // Open stdin
	OpenStdin bool `protobuf:"varint,9,opt,name=open_stdin,json=openStdin,proto3" json:"open_stdin,omitempty"`
	// StdinOnce bool // If true, close stdin after the 1 attached client disconnects.
	StdinOnce bool `protobuf:"varint,10,opt,name=stdin_once,json=stdinOnce,proto3" json:"stdin_once,omitempty"`
	// Env []string  // List of environment variable to set in the container
	Env []string `protobuf:"bytes,11,rep,name=env" json:"env,omitempty"`
	// Cmd strslice.StrSlice // Command to run when starting the container
	// StrSlice represents a string or an array of strings. We need to override the json decoder to accept both options. // type StrSlice []string
	Cmd []string `protobuf:"bytes,12,rep,name=cmd" json:"cmd,omitempty"`
	// Healthcheck *HealthConfig `json:",omitempty"` // Healthcheck describes how to check the container is healthy
	Healthcheck *HealthConfig `protobuf:"bytes,13,opt,name=healthcheck" json:"healthcheck,omitempty"`
	// ArgsEscaped bool `json",omitempty"` // True if command is already escaped (Windows specific)
	ArgsEscaped bool `protobuf:"varint,14,opt,name=args_escaped,json=argsEscaped,proto3" json:"args_escaped,omitempty"`
	// Image string // Name of the image as it was passed by the operator (e.g. could be symbolic)
	Image string `protobuf:"bytes,15,opt,name=image,proto3" json:"image,omitempty"`
	// Volumes map[string]struct{} // List of volumes (mounts) used for the container
	Volumes map[string]*Config_VoidStruct `` /* 142-byte string literal not displayed */
	// WorkingDir string // Current directory (PWD) in the command will be launched
	WorkingDir string `protobuf:"bytes,17,opt,name=working_dir,json=workingDir,proto3" json:"working_dir,omitempty"`
	// Entrypoint strslice.StrSlice // Entrypoint to run when starting the container
	Entrypoint []string `protobuf:"bytes,18,rep,name=entrypoint" json:"entrypoint,omitempty"`
	// NetworkDisabled bool `json:",omitempty"` // Is network disabled
	NetworkDisabled bool `protobuf:"varint,19,opt,name=network_disabled,json=networkDisabled,proto3" json:"network_disabled,omitempty"`
	// MacAddress string `json:",omitempty"` // Mac Address of the container
	MacAddress string `protobuf:"bytes,20,opt,name=mac_address,json=macAddress,proto3" json:"mac_address,omitempty"`
	// OnBuild []string // ONBUILD metadata that were defined on the image Dockerfile
	OnBuild []string `protobuf:"bytes,21,rep,name=on_build,json=onBuild" json:"on_build,omitempty"`
	// Labels map[string]string // List of labels set to this container
	Labels map[string]string `` /* 147-byte string literal not displayed */
	// StopSignal string `json:",omitempty"` // Signal to stop a container
	StopSignal string `protobuf:"bytes,23,opt,name=stop_signal,json=stopSignal,proto3" json:"stop_signal,omitempty"`
	// StopTimeout *int `json:",omitempty"` // Timeout (in seconds) to stop a container
	StopTimeout *Config_Int32Struct `protobuf:"bytes,24,opt,name=stop_timeout,json=stopTimeout" json:"stop_timeout,omitempty"`
	// Shell strslice.StrSlice `json:",omitempty"` // Shell for shell-form of RUN, CMD, ENTRYPOINT
	Shell []string `protobuf:"bytes,25,rep,name=shell" json:"shell,omitempty"`
}

Config contains the configuration data about a container. It should hold only portable information about the container. Here, "portable" means "independent from the host we are running on". Non-portable information *should* appear in HostConfig. All fields added to this struct must be marked 'omitempty' to keep getting predictable hashes from the old 'v1Compatibility' configuration. type Config struct

func ConvertFromDockerApiTypeConfig

func ConvertFromDockerApiTypeConfig(s *containertypes.Config) (dst *Config)

func (*Config) DeepCopyChecked

func (m *Config) DeepCopyChecked() (*Config, []error)

func (*Config) Descriptor

func (*Config) Descriptor() ([]byte, []int)

func (*Config) ExportIntoDockerApiType

func (m *Config) ExportIntoDockerApiType() (tgt *containertypes.Config)

func (*Config) GetArgsEscaped

func (m *Config) GetArgsEscaped() bool

func (*Config) GetAttachStderr

func (m *Config) GetAttachStderr() bool

func (*Config) GetAttachStdin

func (m *Config) GetAttachStdin() bool

func (*Config) GetAttachStdout

func (m *Config) GetAttachStdout() bool

func (*Config) GetCmd

func (m *Config) GetCmd() []string

func (*Config) GetDomainname

func (m *Config) GetDomainname() string

func (*Config) GetEntrypoint

func (m *Config) GetEntrypoint() []string

func (*Config) GetEnv

func (m *Config) GetEnv() []string

func (*Config) GetExposedPorts

func (m *Config) GetExposedPorts() *nat.PortSet

func (*Config) GetHealthcheck

func (m *Config) GetHealthcheck() *HealthConfig

func (*Config) GetHostname

func (m *Config) GetHostname() string

func (*Config) GetImage

func (m *Config) GetImage() string

func (*Config) GetLabels

func (m *Config) GetLabels() map[string]string

func (*Config) GetMacAddress

func (m *Config) GetMacAddress() string

func (*Config) GetNetworkDisabled

func (m *Config) GetNetworkDisabled() bool

func (*Config) GetOnBuild

func (m *Config) GetOnBuild() []string

func (*Config) GetOpenStdin

func (m *Config) GetOpenStdin() bool

func (*Config) GetShell

func (m *Config) GetShell() []string

func (*Config) GetStdinOnce

func (m *Config) GetStdinOnce() bool

func (*Config) GetStopSignal

func (m *Config) GetStopSignal() string

func (*Config) GetStopTimeout

func (m *Config) GetStopTimeout() *Config_Int32Struct

func (*Config) GetTty

func (m *Config) GetTty() bool

func (*Config) GetUser

func (m *Config) GetUser() string

func (*Config) GetVolumes

func (m *Config) GetVolumes() map[string]*Config_VoidStruct

func (*Config) GetWorkingDir

func (m *Config) GetWorkingDir() string

func (*Config) ProtoMessage

func (*Config) ProtoMessage()

func (*Config) Reset

func (m *Config) Reset()

func (*Config) String

func (m *Config) String() string

type Config_Int32Struct

type Config_Int32Struct struct {
	Value int32 `protobuf:"varint,1,opt,name=value,proto3" json:"value,omitempty"`
}

func (*Config_Int32Struct) Descriptor

func (*Config_Int32Struct) Descriptor() ([]byte, []int)

func (*Config_Int32Struct) GetValue

func (m *Config_Int32Struct) GetValue() int32

func (*Config_Int32Struct) ProtoMessage

func (*Config_Int32Struct) ProtoMessage()

func (*Config_Int32Struct) Reset

func (m *Config_Int32Struct) Reset()

func (*Config_Int32Struct) String

func (m *Config_Int32Struct) String() string

type Config_VoidStruct

type Config_VoidStruct struct {
}

func (*Config_VoidStruct) Descriptor

func (*Config_VoidStruct) Descriptor() ([]byte, []int)

func (*Config_VoidStruct) ProtoMessage

func (*Config_VoidStruct) ProtoMessage()

func (*Config_VoidStruct) Reset

func (m *Config_VoidStruct) Reset()

func (*Config_VoidStruct) String

func (m *Config_VoidStruct) String() string

type ContainerCreateCreatedBody

type ContainerCreateCreatedBody struct {
	// The ID of the created container. Required: true
	// ID string `json:"Id"`
	Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	// Warnings encountered when creating the container. Required: true
	// Warnings []string `json:"Warnings"`
	Warnings []string `protobuf:"bytes,2,rep,name=warnings" json:"warnings,omitempty"`
}

ContainerCreateCreatedBody OK response to ContainerCreate operation type ContainerCreateCreatedBody struct

func (*ContainerCreateCreatedBody) Descriptor

func (*ContainerCreateCreatedBody) Descriptor() ([]byte, []int)

func (*ContainerCreateCreatedBody) GetId

func (*ContainerCreateCreatedBody) GetWarnings

func (m *ContainerCreateCreatedBody) GetWarnings() []string

func (*ContainerCreateCreatedBody) ProtoMessage

func (*ContainerCreateCreatedBody) ProtoMessage()

func (*ContainerCreateCreatedBody) Reset

func (m *ContainerCreateCreatedBody) Reset()

func (*ContainerCreateCreatedBody) String

func (m *ContainerCreateCreatedBody) String() string

type DeviceMapping

type DeviceMapping struct {
	// PathOnHost string
	PathOnHost string `protobuf:"bytes,1,opt,name=path_on_host,json=pathOnHost,proto3" json:"path_on_host,omitempty"`
	// PathInContainer string
	PathInContainer string `protobuf:"bytes,2,opt,name=path_in_container,json=pathInContainer,proto3" json:"path_in_container,omitempty"`
	// CgroupPermissions string
	CgroupPermissions string `protobuf:"bytes,3,opt,name=cgroup_permissions,json=cgroupPermissions,proto3" json:"cgroup_permissions,omitempty"`
}

DeviceMapping represents the device mapping between the host and the container. type DeviceMapping struct

func (*DeviceMapping) Descriptor

func (*DeviceMapping) Descriptor() ([]byte, []int)

func (*DeviceMapping) GetCgroupPermissions

func (m *DeviceMapping) GetCgroupPermissions() string

func (*DeviceMapping) GetPathInContainer

func (m *DeviceMapping) GetPathInContainer() string

func (*DeviceMapping) GetPathOnHost

func (m *DeviceMapping) GetPathOnHost() string

func (*DeviceMapping) ProtoMessage

func (*DeviceMapping) ProtoMessage()

func (*DeviceMapping) Reset

func (m *DeviceMapping) Reset()

func (*DeviceMapping) String

func (m *DeviceMapping) String() string

type HealthConfig

type HealthConfig struct {
	// Test []string `json:",omitempty"`
	// Test is the test to perform to check that the container is healthy.
	// An empty slice means to inherit the default.
	// The options are:
	// {} : inherit healthcheck
	// {"NONE"} : disable healthcheck
	// {"CMD", args...} : exec arguments directly
	// {"CMD-SHELL", command} : run command with system's default shell
	Test []string `protobuf:"bytes,1,rep,name=test" json:"test,omitempty"`
	// Zero means to inherit. Durations are expressed as integer nanoseconds.
	// Interval time.Duration `json:",omitempty"` // Interval is the time to wait between checks.
	Interval *google_protobuf.Duration `protobuf:"bytes,2,opt,name=interval" json:"interval,omitempty"`
	// Timeout time.Duration `json:",omitempty"` // Timeout is the time to wait before considering the check to have hung.
	Timeout *google_protobuf.Duration `protobuf:"bytes,3,opt,name=timeout" json:"timeout,omitempty"`
	// StartPeriod time.Duration `json:",omitempty"` // The start period for the container to initialize before the retries starts to count down.
	StartPeriod *google_protobuf.Duration `protobuf:"bytes,4,opt,name=start_period,json=startPeriod" json:"start_period,omitempty"`
	// Retries int `json:",omitempty"`// Retries is the number of consecutive failures needed to consider a container as unhealthy. Zero means inherit.
	Retries int32 `protobuf:"varint,5,opt,name=retries,proto3" json:"retries,omitempty"`
}

HealthConfig holds configuration settings for the HEALTHCHECK feature. type HealthConfig struct

func (*HealthConfig) Descriptor

func (*HealthConfig) Descriptor() ([]byte, []int)

func (*HealthConfig) GetInterval

func (m *HealthConfig) GetInterval() *google_protobuf.Duration

func (*HealthConfig) GetRetries

func (m *HealthConfig) GetRetries() int32

func (*HealthConfig) GetStartPeriod

func (m *HealthConfig) GetStartPeriod() *google_protobuf.Duration

func (*HealthConfig) GetTest

func (m *HealthConfig) GetTest() []string

func (*HealthConfig) GetTimeout

func (m *HealthConfig) GetTimeout() *google_protobuf.Duration

func (*HealthConfig) ProtoMessage

func (*HealthConfig) ProtoMessage()

func (*HealthConfig) Reset

func (m *HealthConfig) Reset()

func (*HealthConfig) String

func (m *HealthConfig) String() string

type HostConfig

type HostConfig struct {
	// Applicable to all platforms
	//
	// Binds []string // List of volume bindings for this container
	Binds []string `protobuf:"bytes,1,rep,name=binds" json:"binds,omitempty"`
	// ContainerIDFile // File (path) where the containerId is written
	ContainerIdFile string `protobuf:"bytes,2,opt,name=container_id_file,json=containerIdFile,proto3" json:"container_id_file,omitempty"`
	// LogConfig LogConfig // Configuration of the logs for this container
	LogConfig *LogConfig `protobuf:"bytes,3,opt,name=log_config,json=logConfig" json:"log_config,omitempty"`
	// NetworkMode NetworkMode // Network mode to use for the container, "none", "default", "container:<id>"
	// NetworkMode represents the container network stack. // type NetworkMode string
	NetworkMode string `protobuf:"bytes,4,opt,name=network_mode,json=networkMode,proto3" json:"network_mode,omitempty"`
	// PortBindings nat.PortMap // Port mapping between the exposed port (container) and the host
	PortBindings *nat.PortMap `protobuf:"bytes,5,opt,name=port_bindings,json=portBindings" json:"port_bindings,omitempty"`
	// RestartPolicy RestartPolicy // Restart policy to be used for the container
	RestartPolicy *RestartPolicy `protobuf:"bytes,6,opt,name=restart_policy,json=restartPolicy" json:"restart_policy,omitempty"`
	// AutoRemove bool // Automatically remove container when it exits
	AutoRemove bool `protobuf:"varint,7,opt,name=auto_remove,json=autoRemove,proto3" json:"auto_remove,omitempty"`
	// VolumeDriver string // Name of the volume driver used to mount volumes
	VolumeDriver string `protobuf:"bytes,8,opt,name=volume_driver,json=volumeDriver,proto3" json:"volume_driver,omitempty"`
	// VolumesFrom []string // List of volumes to take from other container
	VolumesFrom []string `protobuf:"bytes,9,rep,name=volumes_from,json=volumesFrom" json:"volumes_from,omitempty"`
	// Applicable to UNIX platforms
	//
	// CapAdd strslice.StrSlice // List of kernel capabilities to add to the container
	CapAdd []string `protobuf:"bytes,10,rep,name=cap_add,json=capAdd" json:"cap_add,omitempty"`
	// CapDrop strslice.StrSlice // List of kernel capabilities to remove from the container
	CapDrop []string `protobuf:"bytes,11,rep,name=cap_drop,json=capDrop" json:"cap_drop,omitempty"`
	// DNS []string `json:"Dns"` // List of DNS server to lookup
	Dns []string `protobuf:"bytes,12,rep,name=dns" json:"dns,omitempty"`
	// DNSOptions []string `json:"DnsOptions"` // List of DNSOption to look for
	DnsOptions []string `protobuf:"bytes,13,rep,name=dns_options,json=dnsOptions" json:"dns_options,omitempty"`
	// DNSSearch []string `json:"DnsSearch"` // List of DNSSearch to look for
	DnsSearch []string `protobuf:"bytes,14,rep,name=dns_search,json=dnsSearch" json:"dns_search,omitempty"`
	// ExtraHosts []string // List of extra hosts
	ExtraHosts []string `protobuf:"bytes,15,rep,name=extra_hosts,json=extraHosts" json:"extra_hosts,omitempty"`
	// GroupAdd []string // List of additional groups that the container process will run as
	GroupAdd []string `protobuf:"bytes,16,rep,name=group_add,json=groupAdd" json:"group_add,omitempty"`
	// IpcMode IpcMode // IPC namespace to use for the container, "", "host", "container"
	// IpcMode represents the container ipc stack. // type IpcMode string
	IpcMode string `protobuf:"bytes,17,opt,name=ipc_mode,json=ipcMode,proto3" json:"ipc_mode,omitempty"`
	// Cgroup CgroupSpec // Cgroup to use for the container, "container:<id>"
	// CgroupSpec represents the cgroup to use for the container. // type CgroupSpec string
	Cgroup string `protobuf:"bytes,18,opt,name=cgroup,proto3" json:"cgroup,omitempty"`
	// Links []string // List of links (in the name:alias form)
	Links []string `protobuf:"bytes,19,rep,name=links" json:"links,omitempty"`
	// OomScoreAdj int // Container preference for OOM-killing
	OomScoreAdj int32 `protobuf:"varint,20,opt,name=oom_score_adj,json=oomScoreAdj,proto3" json:"oom_score_adj,omitempty"`
	// PidMode PidMode // PID namespace to use for the container
	// PidMode represents the pid namespace of the container. // type PidMode string
	PidMode string `protobuf:"bytes,21,opt,name=pid_mode,json=pidMode,proto3" json:"pid_mode,omitempty"`
	// Privieged bool // Is the container in privileged mode
	Privileged bool `protobuf:"varint,22,opt,name=privileged,proto3" json:"privileged,omitempty"`
	// PublishAllPorts bool // Should docker publish all exposed port for the container
	PublishAllPorts bool `protobuf:"varint,23,opt,name=publish_all_ports,json=publishAllPorts,proto3" json:"publish_all_ports,omitempty"`
	// ReadonlyRootfs bool // Is the container root filesystem in read-only
	ReadonlyRootfs bool `protobuf:"varint,24,opt,name=readonly_rootfs,json=readonlyRootfs,proto3" json:"readonly_rootfs,omitempty"`
	// SecurityOpt []string // List of string values to customize labels for MLS systems, such as SELinux.
	SecurityOpt []string `protobuf:"bytes,25,rep,name=security_opt,json=securityOpt" json:"security_opt,omitempty"`
	// Storage driver options per container.
	// StorageOpt map[string]string `json:",omitempty"`
	StorageOpt map[string]string `` /* 173-byte string literal not displayed */
	// List of tmpfs (mounts) used for the container
	// Tmpfs map[string]string `json:",omitempty"`
	Tmpfs map[string]string `` /* 145-byte string literal not displayed */
	// UTSMode UTSMode // UTSMode represents the UTS namespace of the container. // type UTSMode string
	// UTS namespace to use for the container
	UtsMode string `protobuf:"bytes,28,opt,name=uts_mode,json=utsMode,proto3" json:"uts_mode,omitempty"`
	// UsernsMode UsernsMode // UsernsMode represents userns mode in the container. // type UsernsMode string
	// The user namespace to use for the container
	UsernsMode string `protobuf:"bytes,29,opt,name=userns_mode,json=usernsMode,proto3" json:"userns_mode,omitempty"`
	// ShmSize int64
	// Total shm memory usage
	ShmSize int64 `protobuf:"varint,30,opt,name=shm_size,json=shmSize,proto3" json:"shm_size,omitempty"`
	// Sysctls map[string]string `json:",omitempty"`
	// List of Namespaced sysctls used for the container
	Sysctls map[string]string `` /* 149-byte string literal not displayed */
	// Runtime string `json:",omitempty"`
	// Runtime to use with this container
	Runtime string `protobuf:"bytes,32,opt,name=runtime,proto3" json:"runtime,omitempty"`
	// Applicable to Windows
	//
	// ConsoleSize [2]uint // Initial console size (height,width)
	ConsoleSizeHeight uint32 `protobuf:"varint,33,opt,name=console_size_height,json=consoleSizeHeight,proto3" json:"console_size_height,omitempty"`
	ConsoleSizeWidth  uint32 `protobuf:"varint,34,opt,name=console_size_width,json=consoleSizeWidth,proto3" json:"console_size_width,omitempty"`
	// Isolation Isolation // Isolation technology of the container (e.g. default, hyperv)
	// Isolation represents the isolation technology of a container. The supported values are platform specific // type Isolation string
	Isolation string `protobuf:"bytes,35,opt,name=isolation,proto3" json:"isolation,omitempty"`
	// Contains container's resources (cgroups, ulimits)
	// Resources
	Resources *Resources `protobuf:"bytes,36,opt,name=resources" json:"resources,omitempty"`
	// Mounts specs used by the container
	// Mounts []mount.Mount `json:",omitempty"`
	Mounts []*mount.Mount `protobuf:"bytes,37,rep,name=mounts" json:"mounts,omitempty"`
	// MaskedPaths is the list of paths to be masked inside the container (this overrides the default set of paths)
	// MaskedPaths []string
	MaskedPaths []string `protobuf:"bytes,38,rep,name=masked_paths,json=maskedPaths" json:"masked_paths,omitempty"`
	// ReadonlyPaths is the list of paths to be set as read-only inside the container (this overrides the default set of paths)
	// ReadonlyPaths []string
	ReadonlyPaths []string `protobuf:"bytes,39,rep,name=readonly_paths,json=readonlyPaths" json:"readonly_paths,omitempty"`
	// Run a custom init inside the container, if null, use the daemon's configured settings
	// Init *bool `json:",omitempty"`
	Init *HostConfig_BoolStruct `protobuf:"bytes,40,opt,name=init" json:"init,omitempty"`
}

HostConfig the non-portable Config structure of a container. Here, "non-portable" means "dependent of the host we are running on". Portable information *should* appear in Config. type HostConfig struct

func ConvertFromDockerApiTypeHostConfig

func ConvertFromDockerApiTypeHostConfig(s *containertypes.HostConfig) (d *HostConfig)

func (*HostConfig) DeepCopyChecked

func (m *HostConfig) DeepCopyChecked() (*HostConfig, []error)

func (*HostConfig) Descriptor

func (*HostConfig) Descriptor() ([]byte, []int)

func (*HostConfig) ExportIntoDockerApiType

func (m *HostConfig) ExportIntoDockerApiType() (tgt *containertypes.HostConfig)

func (*HostConfig) GetAutoRemove

func (m *HostConfig) GetAutoRemove() bool

func (*HostConfig) GetBinds

func (m *HostConfig) GetBinds() []string

func (*HostConfig) GetCapAdd

func (m *HostConfig) GetCapAdd() []string

func (*HostConfig) GetCapDrop

func (m *HostConfig) GetCapDrop() []string

func (*HostConfig) GetCgroup

func (m *HostConfig) GetCgroup() string

func (*HostConfig) GetConsoleSizeHeight

func (m *HostConfig) GetConsoleSizeHeight() uint32

func (*HostConfig) GetConsoleSizeWidth

func (m *HostConfig) GetConsoleSizeWidth() uint32

func (*HostConfig) GetContainerIdFile

func (m *HostConfig) GetContainerIdFile() string

func (*HostConfig) GetDns

func (m *HostConfig) GetDns() []string

func (*HostConfig) GetDnsOptions

func (m *HostConfig) GetDnsOptions() []string

func (*HostConfig) GetDnsSearch

func (m *HostConfig) GetDnsSearch() []string

func (*HostConfig) GetExtraHosts

func (m *HostConfig) GetExtraHosts() []string

func (*HostConfig) GetGroupAdd

func (m *HostConfig) GetGroupAdd() []string

func (*HostConfig) GetInit

func (m *HostConfig) GetInit() *HostConfig_BoolStruct

func (*HostConfig) GetIpcMode

func (m *HostConfig) GetIpcMode() string

func (*HostConfig) GetIsolation

func (m *HostConfig) GetIsolation() string
func (m *HostConfig) GetLinks() []string

func (*HostConfig) GetLogConfig

func (m *HostConfig) GetLogConfig() *LogConfig

func (*HostConfig) GetMaskedPaths

func (m *HostConfig) GetMaskedPaths() []string

func (*HostConfig) GetMounts

func (m *HostConfig) GetMounts() []*mount.Mount

func (*HostConfig) GetNetworkMode

func (m *HostConfig) GetNetworkMode() string

func (*HostConfig) GetOomScoreAdj

func (m *HostConfig) GetOomScoreAdj() int32

func (*HostConfig) GetPidMode

func (m *HostConfig) GetPidMode() string

func (*HostConfig) GetPortBindings

func (m *HostConfig) GetPortBindings() *nat.PortMap

func (*HostConfig) GetPrivileged

func (m *HostConfig) GetPrivileged() bool

func (*HostConfig) GetPublishAllPorts

func (m *HostConfig) GetPublishAllPorts() bool

func (*HostConfig) GetReadonlyPaths

func (m *HostConfig) GetReadonlyPaths() []string

func (*HostConfig) GetReadonlyRootfs

func (m *HostConfig) GetReadonlyRootfs() bool

func (*HostConfig) GetResources

func (m *HostConfig) GetResources() *Resources

func (*HostConfig) GetRestartPolicy

func (m *HostConfig) GetRestartPolicy() *RestartPolicy

func (*HostConfig) GetRuntime

func (m *HostConfig) GetRuntime() string

func (*HostConfig) GetSecurityOpt

func (m *HostConfig) GetSecurityOpt() []string

func (*HostConfig) GetShmSize

func (m *HostConfig) GetShmSize() int64

func (*HostConfig) GetStorageOpt

func (m *HostConfig) GetStorageOpt() map[string]string

func (*HostConfig) GetSysctls

func (m *HostConfig) GetSysctls() map[string]string

func (*HostConfig) GetTmpfs

func (m *HostConfig) GetTmpfs() map[string]string

func (*HostConfig) GetUsernsMode

func (m *HostConfig) GetUsernsMode() string

func (*HostConfig) GetUtsMode

func (m *HostConfig) GetUtsMode() string

func (*HostConfig) GetVolumeDriver

func (m *HostConfig) GetVolumeDriver() string

func (*HostConfig) GetVolumesFrom

func (m *HostConfig) GetVolumesFrom() []string

func (*HostConfig) ProtoMessage

func (*HostConfig) ProtoMessage()

func (*HostConfig) Reset

func (m *HostConfig) Reset()

func (*HostConfig) String

func (m *HostConfig) String() string

type HostConfig_BoolStruct

type HostConfig_BoolStruct struct {
	Value bool `protobuf:"varint,1,opt,name=value,proto3" json:"value,omitempty"`
}

func (*HostConfig_BoolStruct) Descriptor

func (*HostConfig_BoolStruct) Descriptor() ([]byte, []int)

func (*HostConfig_BoolStruct) GetValue

func (m *HostConfig_BoolStruct) GetValue() bool

func (*HostConfig_BoolStruct) ProtoMessage

func (*HostConfig_BoolStruct) ProtoMessage()

func (*HostConfig_BoolStruct) Reset

func (m *HostConfig_BoolStruct) Reset()

func (*HostConfig_BoolStruct) String

func (m *HostConfig_BoolStruct) String() string

type LogConfig

type LogConfig struct {
	// Type string // "", "blocking", "non-blocking"
	Type string `protobuf:"bytes,1,opt,name=type,proto3" json:"type,omitempty"`
	// Config map[string]string
	Config map[string]string `` /* 146-byte string literal not displayed */
}

LogConfig represents the logging configuration of the container. type LogConfig struct

func (*LogConfig) Descriptor

func (*LogConfig) Descriptor() ([]byte, []int)

func (*LogConfig) GetConfig

func (m *LogConfig) GetConfig() map[string]string

func (*LogConfig) GetType

func (m *LogConfig) GetType() string

func (*LogConfig) ProtoMessage

func (*LogConfig) ProtoMessage()

func (*LogConfig) Reset

func (m *LogConfig) Reset()

func (*LogConfig) String

func (m *LogConfig) String() string

type Resources

type Resources struct {
	// Applicable to all platforms
	//
	// CPUShares int64 `json:"CpuShares"` // CPU shares (relative weight vs. other containers)
	CpuShares int64 `protobuf:"varint,1,opt,name=cpu_shares,json=cpuShares,proto3" json:"cpu_shares,omitempty"`
	// Memory int64 // Memory limit (in bytes)
	Memory int64 `protobuf:"varint,2,opt,name=memory,proto3" json:"memory,omitempty"`
	// NanoCPUs int64 `json:"NonoCpus"` // CPU quota in units of 10<sup>-9</sup> CPUs.
	NanoCpus int64 `protobuf:"varint,3,opt,name=nano_cpus,json=nanoCpus,proto3" json:"nano_cpus,omitempty"`
	// Applicable to UNIX platforms
	//
	// CgroupParent string // Parent cgroup.
	CgroupParent string `protobuf:"bytes,4,opt,name=cgroup_parent,json=cgroupParent,proto3" json:"cgroup_parent,omitempty"`
	// BlkioWeight uint16 // Block IO weight (relative weight vs. other containers)
	BlkioWeight int32 `protobuf:"varint,5,opt,name=blkio_weight,json=blkioWeight,proto3" json:"blkio_weight,omitempty"`
	// BlkioWeightDevice []*blkiodev.WeightDevice
	BlkioWeightDevice []*blkiodev.WeightDevice `protobuf:"bytes,6,rep,name=blkio_weight_device,json=blkioWeightDevice" json:"blkio_weight_device,omitempty"`
	// BlkioDeviceReadBps []*blkiodev.ThrottleDevice
	BlkioDeviceReadBps []*blkiodev.ThrottleDevice `protobuf:"bytes,7,rep,name=blkio_device_read_bps,json=blkioDeviceReadBps" json:"blkio_device_read_bps,omitempty"`
	// BlkioDeviceWriteBps []*blkiodev.ThrottleDevice
	BlkioDeviceWriteBps []*blkiodev.ThrottleDevice `protobuf:"bytes,8,rep,name=blkio_device_write_bps,json=blkioDeviceWriteBps" json:"blkio_device_write_bps,omitempty"`
	// BlkioDeviceReadIOps []*blkiodev.ThrottleDevice
	BlkioDeviceReadIops []*blkiodev.ThrottleDevice `protobuf:"bytes,9,rep,name=blkio_device_read_iops,json=blkioDeviceReadIops" json:"blkio_device_read_iops,omitempty"`
	// BlkioDeviceWriteIOps []*blkiodev.ThrottleDevice
	BlkioDeviceWriteIops []*blkiodev.ThrottleDevice `protobuf:"bytes,10,rep,name=blkio_device_write_iops,json=blkioDeviceWriteIops" json:"blkio_device_write_iops,omitempty"`
	// CPUPeriod int64 `json:"CpuPeriod"` // CPU CFS (Completely Fair Scheduler) period
	CpuPeriod int64 `protobuf:"varint,11,opt,name=cpu_period,json=cpuPeriod,proto3" json:"cpu_period,omitempty"`
	// CPUQuota int64 `json:"CpuQuota"` // CPU CFS (Completely Fair Scheduler) quota
	CpuQuota int64 `protobuf:"varint,12,opt,name=cpu_quota,json=cpuQuota,proto3" json:"cpu_quota,omitempty"`
	// CPURealtimePeriod int64 `json:"CpuRealtimePeriod"` // CPU real-time period
	CpuRealtimePeriod int64 `protobuf:"varint,13,opt,name=cpu_realtime_period,json=cpuRealtimePeriod,proto3" json:"cpu_realtime_period,omitempty"`
	// CPURealtimeRuntime int64 `json:"CpuRealtimeRuntime"` // CPU real-time runtime
	CpuRealtimeRuntime int64 `protobuf:"varint,14,opt,name=cpu_realtime_runtime,json=cpuRealtimeRuntime,proto3" json:"cpu_realtime_runtime,omitempty"`
	// CpusetCpus string // CpusetCpus 0-2, 0,1
	CpusetCpus string `protobuf:"bytes,15,opt,name=cpuset_cpus,json=cpusetCpus,proto3" json:"cpuset_cpus,omitempty"`
	// CpusetMems string // CpusetMems 0-2, 0,1
	CpusetMems string `protobuf:"bytes,16,opt,name=cpuset_mems,json=cpusetMems,proto3" json:"cpuset_mems,omitempty"`
	// Devices []DeviceMapping // List of devices to map inside the container
	Devices []*DeviceMapping `protobuf:"bytes,17,rep,name=devices" json:"devices,omitempty"`
	// DeviceCgroupRules []string // List of rule to be added to the device cgroup
	DeviceCgroupRules []string `protobuf:"bytes,18,rep,name=device_cgroup_rules,json=deviceCgroupRules" json:"device_cgroup_rules,omitempty"`
	// DiskQuota int64 // Disk limit (in bytes)
	DiskQuota int64 `protobuf:"varint,19,opt,name=disk_quota,json=diskQuota,proto3" json:"disk_quota,omitempty"`
	// KernelMemory int64 // Kernel memory limit (in bytes)
	KernelMemory int64 `protobuf:"varint,20,opt,name=kernel_memory,json=kernelMemory,proto3" json:"kernel_memory,omitempty"`
	// MemoryReservation int64 // Memory soft limit (in bytes)
	MemoryReservation int64 `protobuf:"varint,21,opt,name=memory_reservation,json=memoryReservation,proto3" json:"memory_reservation,omitempty"`
	// MemorySwap int64 // Total memory usage (memory + swap); set -1 to enable unlimited swap
	MemorySwap int64 `protobuf:"varint,22,opt,name=memory_swap,json=memorySwap,proto3" json:"memory_swap,omitempty"`
	// MemorySwappiness *int64 // Tuning container memory swappiness behaviour
	MemorySwappiness *Resources_Int64Struct `protobuf:"bytes,23,opt,name=memory_swappiness,json=memorySwappiness" json:"memory_swappiness,omitempty"`
	// OomKillDisable *bool // Whether to disable OOM Killer or not
	OomKillDisable *Resources_BoolStruct `protobuf:"bytes,24,opt,name=oom_kill_disable,json=oomKillDisable" json:"oom_kill_disable,omitempty"`
	// PidsLimit int64 // Setting pids limit for a container
	PidsLimit int64 `protobuf:"varint,25,opt,name=pids_limit,json=pidsLimit,proto3" json:"pids_limit,omitempty"`
	// Ulimits []*units.Ulimit // List of ulimits to be set in the container
	Ulimits []*units.Ulimit `protobuf:"bytes,26,rep,name=ulimits" json:"ulimits,omitempty"`
	// Applicable to Windows
	//
	// CPUCount int64 // CPU count
	CpuCount int64 `protobuf:"varint,27,opt,name=cpu_count,json=cpuCount,proto3" json:"cpu_count,omitempty"`
	// CPUPercent int64 // CPU percent
	CpuPercent int64 `protobuf:"varint,28,opt,name=cpu_percent,json=cpuPercent,proto3" json:"cpu_percent,omitempty"`
	// IOMaximumIOps uint64 // Maximum IOps for the container system drive
	IoMaximumIops uint64 `protobuf:"varint,29,opt,name=io_maximum_iops,json=ioMaximumIops,proto3" json:"io_maximum_iops,omitempty"`
	// IOMaximumBandwidth // Maximum IO in bytes per second for the container system drive
	IoMaximumBandwidth uint64 `protobuf:"varint,30,opt,name=io_maximum_bandwidth,json=ioMaximumBandwidth,proto3" json:"io_maximum_bandwidth,omitempty"`
}

Resources contains container's resources (cgroups config, ulimits...) to see https://github.com/moby/moby/blob/master/api/types/container/host_config.go

func (*Resources) Descriptor

func (*Resources) Descriptor() ([]byte, []int)

func (*Resources) GetBlkioDeviceReadBps

func (m *Resources) GetBlkioDeviceReadBps() []*blkiodev.ThrottleDevice

func (*Resources) GetBlkioDeviceReadIops

func (m *Resources) GetBlkioDeviceReadIops() []*blkiodev.ThrottleDevice

func (*Resources) GetBlkioDeviceWriteBps

func (m *Resources) GetBlkioDeviceWriteBps() []*blkiodev.ThrottleDevice

func (*Resources) GetBlkioDeviceWriteIops

func (m *Resources) GetBlkioDeviceWriteIops() []*blkiodev.ThrottleDevice

func (*Resources) GetBlkioWeight

func (m *Resources) GetBlkioWeight() int32

func (*Resources) GetBlkioWeightDevice

func (m *Resources) GetBlkioWeightDevice() []*blkiodev.WeightDevice

func (*Resources) GetCgroupParent

func (m *Resources) GetCgroupParent() string

func (*Resources) GetCpuCount

func (m *Resources) GetCpuCount() int64

func (*Resources) GetCpuPercent

func (m *Resources) GetCpuPercent() int64

func (*Resources) GetCpuPeriod

func (m *Resources) GetCpuPeriod() int64

func (*Resources) GetCpuQuota

func (m *Resources) GetCpuQuota() int64

func (*Resources) GetCpuRealtimePeriod

func (m *Resources) GetCpuRealtimePeriod() int64

func (*Resources) GetCpuRealtimeRuntime

func (m *Resources) GetCpuRealtimeRuntime() int64

func (*Resources) GetCpuShares

func (m *Resources) GetCpuShares() int64

func (*Resources) GetCpusetCpus

func (m *Resources) GetCpusetCpus() string

func (*Resources) GetCpusetMems

func (m *Resources) GetCpusetMems() string

func (*Resources) GetDeviceCgroupRules

func (m *Resources) GetDeviceCgroupRules() []string

func (*Resources) GetDevices

func (m *Resources) GetDevices() []*DeviceMapping

func (*Resources) GetDiskQuota

func (m *Resources) GetDiskQuota() int64

func (*Resources) GetIoMaximumBandwidth

func (m *Resources) GetIoMaximumBandwidth() uint64

func (*Resources) GetIoMaximumIops

func (m *Resources) GetIoMaximumIops() uint64

func (*Resources) GetKernelMemory

func (m *Resources) GetKernelMemory() int64

func (*Resources) GetMemory

func (m *Resources) GetMemory() int64

func (*Resources) GetMemoryReservation

func (m *Resources) GetMemoryReservation() int64

func (*Resources) GetMemorySwap

func (m *Resources) GetMemorySwap() int64

func (*Resources) GetMemorySwappiness

func (m *Resources) GetMemorySwappiness() *Resources_Int64Struct

func (*Resources) GetNanoCpus

func (m *Resources) GetNanoCpus() int64

func (*Resources) GetOomKillDisable

func (m *Resources) GetOomKillDisable() *Resources_BoolStruct

func (*Resources) GetPidsLimit

func (m *Resources) GetPidsLimit() int64

func (*Resources) GetUlimits

func (m *Resources) GetUlimits() []*units.Ulimit

func (*Resources) ProtoMessage

func (*Resources) ProtoMessage()

func (*Resources) Reset

func (m *Resources) Reset()

func (*Resources) String

func (m *Resources) String() string

type Resources_BoolStruct

type Resources_BoolStruct struct {
	Value bool `protobuf:"varint,1,opt,name=value,proto3" json:"value,omitempty"`
}

func (*Resources_BoolStruct) Descriptor

func (*Resources_BoolStruct) Descriptor() ([]byte, []int)

func (*Resources_BoolStruct) GetValue

func (m *Resources_BoolStruct) GetValue() bool

func (*Resources_BoolStruct) ProtoMessage

func (*Resources_BoolStruct) ProtoMessage()

func (*Resources_BoolStruct) Reset

func (m *Resources_BoolStruct) Reset()

func (*Resources_BoolStruct) String

func (m *Resources_BoolStruct) String() string

type Resources_Int64Struct

type Resources_Int64Struct struct {
	Value int64 `protobuf:"varint,1,opt,name=value,proto3" json:"value,omitempty"`
}

func (*Resources_Int64Struct) Descriptor

func (*Resources_Int64Struct) Descriptor() ([]byte, []int)

func (*Resources_Int64Struct) GetValue

func (m *Resources_Int64Struct) GetValue() int64

func (*Resources_Int64Struct) ProtoMessage

func (*Resources_Int64Struct) ProtoMessage()

func (*Resources_Int64Struct) Reset

func (m *Resources_Int64Struct) Reset()

func (*Resources_Int64Struct) String

func (m *Resources_Int64Struct) String() string

type RestartPolicy

type RestartPolicy struct {
	// Name string
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// MaximumRetryCount int
	MaximumRetryCount int32 `protobuf:"varint,2,opt,name=maximum_retry_count,json=maximumRetryCount,proto3" json:"maximum_retry_count,omitempty"`
}

RestartPolicy represents the restart policies of the container. type RestartPolicy struct

func (*RestartPolicy) Descriptor

func (*RestartPolicy) Descriptor() ([]byte, []int)

func (*RestartPolicy) GetMaximumRetryCount

func (m *RestartPolicy) GetMaximumRetryCount() int32

func (*RestartPolicy) GetName

func (m *RestartPolicy) GetName() string

func (*RestartPolicy) ProtoMessage

func (*RestartPolicy) ProtoMessage()

func (*RestartPolicy) Reset

func (m *RestartPolicy) Reset()

func (*RestartPolicy) String

func (m *RestartPolicy) String() string

Jump to

Keyboard shortcuts

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