Class: DockerEngineAPI::Models::Container::HostConfig
- Inherits:
-
Internal::Type::BaseModel
- Object
- Internal::Type::BaseModel
- DockerEngineAPI::Models::Container::HostConfig
- Defined in:
- lib/docker_engine_api/models/container.rb
Overview
Defined Under Namespace
Modules: CgroupnsMode, Isolation Classes: BlkioDeviceReadBp, BlkioDeviceReadIOp, BlkioDeviceWriteBp, BlkioDeviceWriteIOp, BlkioWeightDevice, Device, DeviceRequest, LogConfig, Mount, PortBinding, RestartPolicy, Ulimit
Instance Attribute Summary collapse
-
#annotations ⇒ Hash{Symbol=>String}?
Arbitrary non-identifying metadata attached to container and provided to the runtime when the container is started.
-
#auto_remove ⇒ Boolean?
Automatically remove the container when the container’s process exits.
-
#binds ⇒ Array<String>?
A list of volume bindings for this container.
-
#blkio_device_read_bps ⇒ Array<DockerEngineAPI::Models::Container::HostConfig::BlkioDeviceReadBp>?
Limit read rate (bytes per second) from a device, in the form:.
-
#blkio_device_read_i_ops ⇒ Array<DockerEngineAPI::Models::Container::HostConfig::BlkioDeviceReadIOp>?
Limit read rate (IO per second) from a device, in the form:.
-
#blkio_device_write_bps ⇒ Array<DockerEngineAPI::Models::Container::HostConfig::BlkioDeviceWriteBp>?
Limit write rate (bytes per second) to a device, in the form:.
-
#blkio_device_write_i_ops ⇒ Array<DockerEngineAPI::Models::Container::HostConfig::BlkioDeviceWriteIOp>?
Limit write rate (IO per second) to a device, in the form:.
-
#blkio_weight ⇒ Integer?
Block IO weight (relative weight).
-
#blkio_weight_device ⇒ Array<DockerEngineAPI::Models::Container::HostConfig::BlkioWeightDevice>?
Block IO weight (relative device weight) in the form:.
-
#cap_add ⇒ Array<String>?
A list of kernel capabilities to add to the container.
-
#cap_drop ⇒ Array<String>?
A list of kernel capabilities to drop from the container.
-
#cgroup ⇒ String?
Cgroup to use for the container.
-
#cgroup_parent ⇒ String?
Path to
cgroupsunder which the container’scgroupis created. -
#cgroupns_mode ⇒ Symbol, ...
cgroup namespace mode for the container.
-
#console_size ⇒ Array<Integer>?
Initial console size, as an ‘[height, width]` array.
-
#container_id_file ⇒ String?
Path to a file where the container ID is written.
-
#cpu_count ⇒ Integer?
The number of usable CPUs (Windows only).
-
#cpu_percent ⇒ Integer?
The usable percentage of the available CPUs (Windows only).
-
#cpu_period ⇒ Integer?
The length of a CPU period in microseconds.
-
#cpu_quota ⇒ Integer?
Microseconds of CPU time that the container can get in a CPU period.
-
#cpu_realtime_period ⇒ Integer?
The length of a CPU real-time period in microseconds.
-
#cpu_realtime_runtime ⇒ Integer?
The length of a CPU real-time runtime in microseconds.
-
#cpu_shares ⇒ Integer?
An integer value representing this container’s relative CPU weight versus other containers.
-
#cpuset_cpus ⇒ String?
CPUs in which to allow execution (e.g.,
0-3, ‘0,1`). -
#cpuset_mems ⇒ String?
Memory nodes (MEMs) in which to allow execution (0-3, 0,1).
-
#device_cgroup_rules ⇒ Array<String>?
a list of cgroup rules to apply to the container.
-
#device_requests ⇒ Array<DockerEngineAPI::Models::Container::HostConfig::DeviceRequest>?
A list of requests for devices to be sent to device drivers.
-
#devices ⇒ Array<DockerEngineAPI::Models::Container::HostConfig::Device>?
A list of devices to add to the container.
-
#dns ⇒ Array<String>?
A list of DNS servers for the container to use.
-
#dns_options ⇒ Array<String>?
A list of DNS options.
-
#dns_search ⇒ Array<String>?
A list of DNS search domains.
-
#extra_hosts ⇒ Array<String>?
A list of hostnames/IP mappings to add to the container’s
/etc/hostsfile. -
#group_add ⇒ Array<String>?
A list of additional groups that the container process will run as.
-
#init ⇒ Boolean?
Run an init inside the container that forwards signals and reaps processes.
-
#io_maximum_bandwidth ⇒ Integer?
Maximum IO in bytes per second for the container system drive (Windows only).
-
#io_maximum_i_ops ⇒ Integer?
Maximum IOps for the container system drive (Windows only).
-
#ipc_mode ⇒ String?
IPC sharing mode for the container.
-
#isolation ⇒ Symbol, ...
Isolation technology of the container.
-
#links ⇒ Array<String>?
A list of links for the container in the form
container_name:alias. -
#log_config ⇒ DockerEngineAPI::Models::Container::HostConfig::LogConfig?
The logging configuration for this container.
-
#masked_paths ⇒ Array<String>?
The list of paths to be masked inside the container (this overrides the default set of paths).
-
#memory ⇒ Integer?
Memory limit in bytes.
-
#memory_reservation ⇒ Integer?
Memory soft limit in bytes.
-
#memory_swap ⇒ Integer?
Total memory limit (memory + swap).
-
#memory_swappiness ⇒ Integer?
Tune a container’s memory swappiness behavior.
-
#mounts ⇒ Array<DockerEngineAPI::Models::Container::HostConfig::Mount>?
Specification for mounts to be added to the container.
-
#nano_cpus ⇒ Integer?
CPU quota in units of 10<sup>-9</sup> CPUs.
-
#network_mode ⇒ String?
Network mode to use for this container.
-
#oom_kill_disable ⇒ Boolean?
Disable OOM Killer for the container.
-
#oom_score_adj ⇒ Integer?
An integer value containing the score given to the container in order to tune OOM killer preferences.
-
#pid_mode ⇒ String?
Set the PID (Process) Namespace mode for the container.
-
#pids_limit ⇒ Integer?
Tune a container’s PIDs limit.
-
#port_bindings ⇒ Hash{Symbol=>Array<DockerEngineAPI::Models::Container::HostConfig::PortBinding>}?
PortMap describes the mapping of container ports to host ports, using the container’s port-number and protocol as key in the format ‘<port>/<protocol>`, for example,
80/udp. -
#privileged ⇒ Boolean?
Gives the container full access to the host.
-
#publish_all_ports ⇒ Boolean?
Allocates an ephemeral host port for all of a container’s exposed ports.
-
#readonly_paths ⇒ Array<String>?
The list of paths to be set as read-only inside the container (this overrides the default set of paths).
-
#readonly_rootfs ⇒ Boolean?
Mount the container’s root filesystem as read only.
-
#restart_policy ⇒ DockerEngineAPI::Models::Container::HostConfig::RestartPolicy?
The behavior to apply when the container exits.
-
#runtime ⇒ String?
Runtime to use with this container.
-
#security_opt ⇒ Array<String>?
A list of string values to customize labels for MLS systems, such as SELinux.
-
#shm_size ⇒ Integer?
Size of
/dev/shmin bytes. -
#storage_opt ⇒ Hash{Symbol=>String}?
Storage driver options for this container, in the form ‘“120G”`.
-
#sysctls ⇒ Hash{Symbol=>String}?
A list of kernel parameters (sysctls) to set in the container.
-
#tmpfs ⇒ Hash{Symbol=>String}?
A map of container directories which should be replaced by tmpfs mounts, and their corresponding mount options.
-
#ulimits ⇒ Array<DockerEngineAPI::Models::Container::HostConfig::Ulimit>?
A list of resource limits to set in the container.
-
#userns_mode ⇒ String?
Sets the usernamespace mode for the container when usernamespace remapping option is enabled.
-
#uts_mode ⇒ String?
UTS namespace to use for the container.
-
#volume_driver ⇒ String?
Driver that this container uses to mount volumes.
-
#volumes_from ⇒ Array<String>?
A list of volumes to inherit from another container, specified in the form ‘<container name>`.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(host_ip: nil, host_port: nil) ⇒ Object
constructor
PortBinding represents a binding between a host IP address and a host port.
Methods inherited from Internal::Type::BaseModel
==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml
Methods included from Internal::Type::Converter
#coerce, coerce, #dump, dump, inspect, #inspect, meta_info, new_coerce_state, type_info
Methods included from Internal::Util::SorbetRuntimeSupport
#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type
Constructor Details
#initialize(host_ip: nil, host_port: nil) ⇒ Object
PortBinding represents a binding between a host IP address and a host port.
|
|
# File 'lib/docker_engine_api/models/container.rb', line 1050
|
Instance Attribute Details
#annotations ⇒ Hash{Symbol=>String}?
Arbitrary non-identifying metadata attached to container and provided to the runtime when the container is started.
304 |
# File 'lib/docker_engine_api/models/container.rb', line 304 optional :annotations, DockerEngineAPI::Internal::Type::HashOf[String], api_name: :Annotations |
#auto_remove ⇒ Boolean?
Automatically remove the container when the container’s process exits. This has no effect if RestartPolicy is set.
311 |
# File 'lib/docker_engine_api/models/container.rb', line 311 optional :auto_remove, DockerEngineAPI::Internal::Type::Boolean, api_name: :AutoRemove |
#binds ⇒ Array<String>?
A list of volume bindings for this container. Each volume binding is a string in one of these forms:
-
host-src:container-dest[:options]to bind-mount a host path into the container. Bothhost-src, andcontainer-destmust be an absolute path. -
volume-name:container-dest[:options]to bind-mount a volume managed by a volume driver into the container.container-destmust be an absolute path.
options is an optional, comma-delimited list of:
-
nocopydisables automatic copying of data from the container path to the volume. Thenocopyflag only applies to named volumes. -
‘[ro|rw]` mounts a volume read-only or read-write, respectively. If omitted or set to
rw, volumes are mounted read-write. -
‘[z|Z]` applies SELinux labels to allow or deny multiple containers to read and write to the same volume.
-
z: a shared content label is applied to the content. This label indicates that multiple containers can share the volume content, for both reading and writing. -
Z: a _private unshared_ label is applied to the content. This label indicates that only the current container can use a private volume. Labeling systems such as SELinux require proper labels to be placed on volume content that is mounted into a container. Without a label, the security system can prevent a container’s processes from using the content. By default, the labels set by the host operating system are not modified.
-
-
‘[[r]shared|slave|private]` specifies mount [propagation behavior](www.kernel.org/doc/Documentation/filesystems/sharedsubtree.txt). This only applies to bind-mounted volumes, not internal volumes or named volumes. Mount propagation requires the source mount point (the location where the source directory is mounted in the host operating system) to have the correct propagation properties. For shared volumes, the source mount point must be set to
shared. For slave volumes, the mount must be set to eithersharedorslave.
349 |
# File 'lib/docker_engine_api/models/container.rb', line 349 optional :binds, DockerEngineAPI::Internal::Type::ArrayOf[String], api_name: :Binds |
#blkio_device_read_bps ⇒ Array<DockerEngineAPI::Models::Container::HostConfig::BlkioDeviceReadBp>?
Limit read rate (bytes per second) from a device, in the form:
“‘
- “device_path”, “Rate”: rate
-
“‘
359 360 361 362 363 |
# File 'lib/docker_engine_api/models/container.rb', line 359 optional :blkio_device_read_bps, -> { DockerEngineAPI::Internal::Type::ArrayOf[DockerEngineAPI::Container::HostConfig::BlkioDeviceReadBp] }, api_name: :BlkioDeviceReadBps |
#blkio_device_read_i_ops ⇒ Array<DockerEngineAPI::Models::Container::HostConfig::BlkioDeviceReadIOp>?
Limit read rate (IO per second) from a device, in the form:
“‘
- “device_path”, “Rate”: rate
-
“‘
373 374 375 376 377 |
# File 'lib/docker_engine_api/models/container.rb', line 373 optional :blkio_device_read_i_ops, -> { DockerEngineAPI::Internal::Type::ArrayOf[DockerEngineAPI::Container::HostConfig::BlkioDeviceReadIOp] }, api_name: :BlkioDeviceReadIOps |
#blkio_device_write_bps ⇒ Array<DockerEngineAPI::Models::Container::HostConfig::BlkioDeviceWriteBp>?
Limit write rate (bytes per second) to a device, in the form:
“‘
- “device_path”, “Rate”: rate
-
“‘
387 388 389 390 391 |
# File 'lib/docker_engine_api/models/container.rb', line 387 optional :blkio_device_write_bps, -> { DockerEngineAPI::Internal::Type::ArrayOf[DockerEngineAPI::Container::HostConfig::BlkioDeviceWriteBp] }, api_name: :BlkioDeviceWriteBps |
#blkio_device_write_i_ops ⇒ Array<DockerEngineAPI::Models::Container::HostConfig::BlkioDeviceWriteIOp>?
Limit write rate (IO per second) to a device, in the form:
“‘
- “device_path”, “Rate”: rate
-
“‘
401 402 403 404 405 |
# File 'lib/docker_engine_api/models/container.rb', line 401 optional :blkio_device_write_i_ops, -> { DockerEngineAPI::Internal::Type::ArrayOf[DockerEngineAPI::Container::HostConfig::BlkioDeviceWriteIOp] }, api_name: :BlkioDeviceWriteIOps |
#blkio_weight ⇒ Integer?
Block IO weight (relative weight).
411 |
# File 'lib/docker_engine_api/models/container.rb', line 411 optional :blkio_weight, Integer, api_name: :BlkioWeight |
#blkio_weight_device ⇒ Array<DockerEngineAPI::Models::Container::HostConfig::BlkioWeightDevice>?
Block IO weight (relative device weight) in the form:
“‘
- “device_path”, “Weight”: weight
-
“‘
421 422 423 424 425 |
# File 'lib/docker_engine_api/models/container.rb', line 421 optional :blkio_weight_device, -> { DockerEngineAPI::Internal::Type::ArrayOf[DockerEngineAPI::Container::HostConfig::BlkioWeightDevice] }, api_name: :BlkioWeightDevice |
#cap_add ⇒ Array<String>?
A list of kernel capabilities to add to the container. Conflicts with option ‘Capabilities’.
432 |
# File 'lib/docker_engine_api/models/container.rb', line 432 optional :cap_add, DockerEngineAPI::Internal::Type::ArrayOf[String], api_name: :CapAdd |
#cap_drop ⇒ Array<String>?
A list of kernel capabilities to drop from the container. Conflicts with option ‘Capabilities’.
439 |
# File 'lib/docker_engine_api/models/container.rb', line 439 optional :cap_drop, DockerEngineAPI::Internal::Type::ArrayOf[String], api_name: :CapDrop |
#cgroup ⇒ String?
Cgroup to use for the container.
445 |
# File 'lib/docker_engine_api/models/container.rb', line 445 optional :cgroup, String, api_name: :Cgroup |
#cgroup_parent ⇒ String?
Path to cgroups under which the container’s cgroup is created. If the path is not absolute, the path is considered to be relative to the cgroups path of the init process. Cgroups are created if they do not already exist.
467 |
# File 'lib/docker_engine_api/models/container.rb', line 467 optional :cgroup_parent, String, api_name: :CgroupParent |
#cgroupns_mode ⇒ Symbol, ...
cgroup namespace mode for the container. Possible values are:
-
‘“private”`: the container runs in its own private cgroup namespace
-
‘“host”`: use the host system’s cgroup namespace
If not specified, the daemon default is used, which can either be ‘“private”` or `“host”`, depending on daemon version, kernel support and configuration.
457 458 459 |
# File 'lib/docker_engine_api/models/container.rb', line 457 optional :cgroupns_mode, enum: -> { DockerEngineAPI::Container::HostConfig::CgroupnsMode }, api_name: :CgroupnsMode |
#console_size ⇒ Array<Integer>?
Initial console size, as an ‘[height, width]` array.
473 474 475 476 |
# File 'lib/docker_engine_api/models/container.rb', line 473 optional :console_size, DockerEngineAPI::Internal::Type::ArrayOf[Integer], api_name: :ConsoleSize, nil?: true |
#container_id_file ⇒ String?
Path to a file where the container ID is written
482 |
# File 'lib/docker_engine_api/models/container.rb', line 482 optional :container_id_file, String, api_name: :ContainerIDFile |
#cpu_count ⇒ Integer?
The number of usable CPUs (Windows only).
On Windows Server containers, the processor resource controls are mutually exclusive. The order of precedence is CPUCount first, then CPUShares, and CPUPercent last.
492 |
# File 'lib/docker_engine_api/models/container.rb', line 492 optional :cpu_count, Integer, api_name: :CpuCount |
#cpu_percent ⇒ Integer?
The usable percentage of the available CPUs (Windows only).
On Windows Server containers, the processor resource controls are mutually exclusive. The order of precedence is CPUCount first, then CPUShares, and CPUPercent last.
502 |
# File 'lib/docker_engine_api/models/container.rb', line 502 optional :cpu_percent, Integer, api_name: :CpuPercent |
#cpu_period ⇒ Integer?
The length of a CPU period in microseconds.
508 |
# File 'lib/docker_engine_api/models/container.rb', line 508 optional :cpu_period, Integer, api_name: :CpuPeriod |
#cpu_quota ⇒ Integer?
Microseconds of CPU time that the container can get in a CPU period.
514 |
# File 'lib/docker_engine_api/models/container.rb', line 514 optional :cpu_quota, Integer, api_name: :CpuQuota |
#cpu_realtime_period ⇒ Integer?
The length of a CPU real-time period in microseconds. Set to 0 to allocate no time allocated to real-time tasks.
521 |
# File 'lib/docker_engine_api/models/container.rb', line 521 optional :cpu_realtime_period, Integer, api_name: :CpuRealtimePeriod |
#cpu_realtime_runtime ⇒ Integer?
The length of a CPU real-time runtime in microseconds. Set to 0 to allocate no time allocated to real-time tasks.
528 |
# File 'lib/docker_engine_api/models/container.rb', line 528 optional :cpu_realtime_runtime, Integer, api_name: :CpuRealtimeRuntime |
#cpu_shares ⇒ Integer?
An integer value representing this container’s relative CPU weight versus other containers.
548 |
# File 'lib/docker_engine_api/models/container.rb', line 548 optional :cpu_shares, Integer, api_name: :CpuShares |
#cpuset_cpus ⇒ String?
CPUs in which to allow execution (e.g., 0-3, ‘0,1`).
534 |
# File 'lib/docker_engine_api/models/container.rb', line 534 optional :cpuset_cpus, String, api_name: :CpusetCpus |
#cpuset_mems ⇒ String?
Memory nodes (MEMs) in which to allow execution (0-3, 0,1). Only effective on NUMA systems.
541 |
# File 'lib/docker_engine_api/models/container.rb', line 541 optional :cpuset_mems, String, api_name: :CpusetMems |
#device_cgroup_rules ⇒ Array<String>?
a list of cgroup rules to apply to the container
554 555 556 |
# File 'lib/docker_engine_api/models/container.rb', line 554 optional :device_cgroup_rules, DockerEngineAPI::Internal::Type::ArrayOf[String], api_name: :DeviceCgroupRules |
#device_requests ⇒ Array<DockerEngineAPI::Models::Container::HostConfig::DeviceRequest>?
A list of requests for devices to be sent to device drivers.
562 563 564 565 566 |
# File 'lib/docker_engine_api/models/container.rb', line 562 optional :device_requests, -> { DockerEngineAPI::Internal::Type::ArrayOf[DockerEngineAPI::Container::HostConfig::DeviceRequest] }, api_name: :DeviceRequests |
#devices ⇒ Array<DockerEngineAPI::Models::Container::HostConfig::Device>?
A list of devices to add to the container.
572 573 574 575 576 |
# File 'lib/docker_engine_api/models/container.rb', line 572 optional :devices, -> { DockerEngineAPI::Internal::Type::ArrayOf[DockerEngineAPI::Container::HostConfig::Device] }, api_name: :Devices |
#dns ⇒ Array<String>?
A list of DNS servers for the container to use.
582 |
# File 'lib/docker_engine_api/models/container.rb', line 582 optional :dns, DockerEngineAPI::Internal::Type::ArrayOf[String], api_name: :Dns |
#dns_options ⇒ Array<String>?
A list of DNS options.
588 |
# File 'lib/docker_engine_api/models/container.rb', line 588 optional :dns_options, DockerEngineAPI::Internal::Type::ArrayOf[String], api_name: :DnsOptions |
#dns_search ⇒ Array<String>?
A list of DNS search domains.
594 |
# File 'lib/docker_engine_api/models/container.rb', line 594 optional :dns_search, DockerEngineAPI::Internal::Type::ArrayOf[String], api_name: :DnsSearch |
#extra_hosts ⇒ Array<String>?
A list of hostnames/IP mappings to add to the container’s /etc/hosts file. Specified in the form ‘[“hostname:IP”]`.
601 |
# File 'lib/docker_engine_api/models/container.rb', line 601 optional :extra_hosts, DockerEngineAPI::Internal::Type::ArrayOf[String], api_name: :ExtraHosts |
#group_add ⇒ Array<String>?
A list of additional groups that the container process will run as.
607 |
# File 'lib/docker_engine_api/models/container.rb', line 607 optional :group_add, DockerEngineAPI::Internal::Type::ArrayOf[String], api_name: :GroupAdd |
#init ⇒ Boolean?
Run an init inside the container that forwards signals and reaps processes. This field is omitted if empty, and the default (as configured on the daemon) is used.
615 |
# File 'lib/docker_engine_api/models/container.rb', line 615 optional :init, DockerEngineAPI::Internal::Type::Boolean, api_name: :Init, nil?: true |
#io_maximum_bandwidth ⇒ Integer?
Maximum IO in bytes per second for the container system drive (Windows only).
621 |
# File 'lib/docker_engine_api/models/container.rb', line 621 optional :io_maximum_bandwidth, Integer, api_name: :IOMaximumBandwidth |
#io_maximum_i_ops ⇒ Integer?
Maximum IOps for the container system drive (Windows only)
627 |
# File 'lib/docker_engine_api/models/container.rb', line 627 optional :io_maximum_i_ops, Integer, api_name: :IOMaximumIOps |
#ipc_mode ⇒ String?
IPC sharing mode for the container. Possible values are:
-
‘“none”`: own private IPC namespace, with /dev/shm not mounted
-
‘“private”`: own private IPC namespace
-
‘“shareable”`: own private IPC namespace, with a possibility to share it with other containers
-
‘“container:<name|id>”`: join another (shareable) container’s IPC namespace
-
‘“host”`: use the host system’s IPC namespace
If not specified, daemon default is used, which can either be ‘“private”` or `“shareable”`, depending on daemon version and configuration.
643 |
# File 'lib/docker_engine_api/models/container.rb', line 643 optional :ipc_mode, String, api_name: :IpcMode |
#isolation ⇒ Symbol, ...
Isolation technology of the container. (Windows only)
649 650 651 652 653 |
# File 'lib/docker_engine_api/models/container.rb', line 649 optional :isolation, enum: -> { DockerEngineAPI::Container::HostConfig::Isolation }, api_name: :Isolation |
#links ⇒ Array<String>?
A list of links for the container in the form container_name:alias.
659 |
# File 'lib/docker_engine_api/models/container.rb', line 659 optional :links, DockerEngineAPI::Internal::Type::ArrayOf[String], api_name: :Links |
#log_config ⇒ DockerEngineAPI::Models::Container::HostConfig::LogConfig?
The logging configuration for this container
665 |
# File 'lib/docker_engine_api/models/container.rb', line 665 optional :log_config, -> { DockerEngineAPI::Container::HostConfig::LogConfig }, api_name: :LogConfig |
#masked_paths ⇒ Array<String>?
The list of paths to be masked inside the container (this overrides the default set of paths).
672 |
# File 'lib/docker_engine_api/models/container.rb', line 672 optional :masked_paths, DockerEngineAPI::Internal::Type::ArrayOf[String], api_name: :MaskedPaths |
#memory ⇒ Integer?
Memory limit in bytes.
678 |
# File 'lib/docker_engine_api/models/container.rb', line 678 optional :memory, Integer, api_name: :Memory |
#memory_reservation ⇒ Integer?
Memory soft limit in bytes.
684 |
# File 'lib/docker_engine_api/models/container.rb', line 684 optional :memory_reservation, Integer, api_name: :MemoryReservation |
#memory_swap ⇒ Integer?
Total memory limit (memory + swap). Set as -1 to enable unlimited swap.
690 |
# File 'lib/docker_engine_api/models/container.rb', line 690 optional :memory_swap, Integer, api_name: :MemorySwap |
#memory_swappiness ⇒ Integer?
Tune a container’s memory swappiness behavior. Accepts an integer between 0 and 100.
697 |
# File 'lib/docker_engine_api/models/container.rb', line 697 optional :memory_swappiness, Integer, api_name: :MemorySwappiness |
#mounts ⇒ Array<DockerEngineAPI::Models::Container::HostConfig::Mount>?
Specification for mounts to be added to the container.
703 704 705 706 707 |
# File 'lib/docker_engine_api/models/container.rb', line 703 optional :mounts, -> { DockerEngineAPI::Internal::Type::ArrayOf[DockerEngineAPI::Container::HostConfig::Mount] }, api_name: :Mounts |
#nano_cpus ⇒ Integer?
CPU quota in units of 10<sup>-9</sup> CPUs.
713 |
# File 'lib/docker_engine_api/models/container.rb', line 713 optional :nano_cpus, Integer, api_name: :NanoCpus |
#network_mode ⇒ String?
Network mode to use for this container. Supported standard values are: bridge, host, none, and ‘container:<name|id>`. Any other value is taken as a custom network’s name to which this container should connect to.
721 |
# File 'lib/docker_engine_api/models/container.rb', line 721 optional :network_mode, String, api_name: :NetworkMode |
#oom_kill_disable ⇒ Boolean?
Disable OOM Killer for the container.
727 |
# File 'lib/docker_engine_api/models/container.rb', line 727 optional :oom_kill_disable, DockerEngineAPI::Internal::Type::Boolean, api_name: :OomKillDisable |
#oom_score_adj ⇒ Integer?
An integer value containing the score given to the container in order to tune OOM killer preferences.
734 |
# File 'lib/docker_engine_api/models/container.rb', line 734 optional :oom_score_adj, Integer, api_name: :OomScoreAdj |
#pid_mode ⇒ String?
Set the PID (Process) Namespace mode for the container. It can be either:
-
‘“container:<name|id>”`: joins another container’s PID namespace
-
‘“host”`: use the host’s PID namespace inside the container
743 |
# File 'lib/docker_engine_api/models/container.rb', line 743 optional :pid_mode, String, api_name: :PidMode |
#pids_limit ⇒ Integer?
Tune a container’s PIDs limit. Set 0 or -1 for unlimited, or null to not change.
750 |
# File 'lib/docker_engine_api/models/container.rb', line 750 optional :pids_limit, Integer, api_name: :PidsLimit, nil?: true |
#port_bindings ⇒ Hash{Symbol=>Array<DockerEngineAPI::Models::Container::HostConfig::PortBinding>}?
PortMap describes the mapping of container ports to host ports, using the container’s port-number and protocol as key in the format ‘<port>/<protocol>`, for example, 80/udp.
If a container’s port is mapped for multiple protocols, separate entries are added to the mapping table.
761 762 763 764 765 |
# File 'lib/docker_engine_api/models/container.rb', line 761 optional :port_bindings, -> { DockerEngineAPI::Internal::Type::HashOf[DockerEngineAPI::Internal::Type::ArrayOf[DockerEngineAPI::Container::HostConfig::PortBinding]] }, api_name: :PortBindings |
#privileged ⇒ Boolean?
Gives the container full access to the host.
771 |
# File 'lib/docker_engine_api/models/container.rb', line 771 optional :privileged, DockerEngineAPI::Internal::Type::Boolean, api_name: :Privileged |
#publish_all_ports ⇒ Boolean?
Allocates an ephemeral host port for all of a container’s exposed ports.
Ports are de-allocated when the container stops and allocated when the container starts. The allocated port might be changed when restarting the container.
The port is selected from the ephemeral port range that depends on the kernel. For example, on Linux the range is defined by /proc/sys/net/ipv4/ip_local_port_range.
784 |
# File 'lib/docker_engine_api/models/container.rb', line 784 optional :publish_all_ports, DockerEngineAPI::Internal::Type::Boolean, api_name: :PublishAllPorts |
#readonly_paths ⇒ Array<String>?
The list of paths to be set as read-only inside the container (this overrides the default set of paths).
791 |
# File 'lib/docker_engine_api/models/container.rb', line 791 optional :readonly_paths, DockerEngineAPI::Internal::Type::ArrayOf[String], api_name: :ReadonlyPaths |
#readonly_rootfs ⇒ Boolean?
Mount the container’s root filesystem as read only.
797 |
# File 'lib/docker_engine_api/models/container.rb', line 797 optional :readonly_rootfs, DockerEngineAPI::Internal::Type::Boolean, api_name: :ReadonlyRootfs |
#restart_policy ⇒ DockerEngineAPI::Models::Container::HostConfig::RestartPolicy?
The behavior to apply when the container exits. The default is not to restart.
An ever increasing delay (double the previous delay, starting at 100ms) is added before each restart to prevent flooding the server.
806 807 808 |
# File 'lib/docker_engine_api/models/container.rb', line 806 optional :restart_policy, -> { DockerEngineAPI::Container::HostConfig::RestartPolicy }, api_name: :RestartPolicy |
#runtime ⇒ String?
Runtime to use with this container.
814 |
# File 'lib/docker_engine_api/models/container.rb', line 814 optional :runtime, String, api_name: :Runtime, nil?: true |
#security_opt ⇒ Array<String>?
A list of string values to customize labels for MLS systems, such as SELinux.
820 |
# File 'lib/docker_engine_api/models/container.rb', line 820 optional :security_opt, DockerEngineAPI::Internal::Type::ArrayOf[String], api_name: :SecurityOpt |
#shm_size ⇒ Integer?
Size of /dev/shm in bytes. If omitted, the system uses 64MB.
826 |
# File 'lib/docker_engine_api/models/container.rb', line 826 optional :shm_size, Integer, api_name: :ShmSize |
#storage_opt ⇒ Hash{Symbol=>String}?
Storage driver options for this container, in the form ‘“120G”`.
832 |
# File 'lib/docker_engine_api/models/container.rb', line 832 optional :storage_opt, DockerEngineAPI::Internal::Type::HashOf[String], api_name: :StorageOpt |
#sysctls ⇒ Hash{Symbol=>String}?
A list of kernel parameters (sysctls) to set in the container.
This field is omitted if not set.
840 |
# File 'lib/docker_engine_api/models/container.rb', line 840 optional :sysctls, DockerEngineAPI::Internal::Type::HashOf[String], api_name: :Sysctls, nil?: true |
#tmpfs ⇒ Hash{Symbol=>String}?
A map of container directories which should be replaced by tmpfs mounts, and their corresponding mount options. For example:
“‘ { “/run”: “rw,noexec,nosuid,size=65536k” } “`
851 |
# File 'lib/docker_engine_api/models/container.rb', line 851 optional :tmpfs, DockerEngineAPI::Internal::Type::HashOf[String], api_name: :Tmpfs |
#ulimits ⇒ Array<DockerEngineAPI::Models::Container::HostConfig::Ulimit>?
A list of resource limits to set in the container. For example:
“‘ “nofile”, “Soft”: 1024, “Hard”: 2048 “`
861 862 863 864 865 |
# File 'lib/docker_engine_api/models/container.rb', line 861 optional :ulimits, -> { DockerEngineAPI::Internal::Type::ArrayOf[DockerEngineAPI::Container::HostConfig::Ulimit] }, api_name: :Ulimits |
#userns_mode ⇒ String?
Sets the usernamespace mode for the container when usernamespace remapping option is enabled.
872 |
# File 'lib/docker_engine_api/models/container.rb', line 872 optional :userns_mode, String, api_name: :UsernsMode |
#uts_mode ⇒ String?
UTS namespace to use for the container.
878 |
# File 'lib/docker_engine_api/models/container.rb', line 878 optional :uts_mode, String, api_name: :UTSMode |
#volume_driver ⇒ String?
Driver that this container uses to mount volumes.
884 |
# File 'lib/docker_engine_api/models/container.rb', line 884 optional :volume_driver, String, api_name: :VolumeDriver |
#volumes_from ⇒ Array<String>?
A list of volumes to inherit from another container, specified in the form ‘<container name>`.
891 |
# File 'lib/docker_engine_api/models/container.rb', line 891 optional :volumes_from, DockerEngineAPI::Internal::Type::ArrayOf[String], api_name: :VolumesFrom |
Class Method Details
.values ⇒ Array<Symbol>
|
|
# File 'lib/docker_engine_api/models/container.rb', line 1144
|