pub struct ContainerSpec {Show 22 fields
pub hostname: Option<String>,
pub domainname: Option<String>,
pub user: Option<String>,
pub env: Vec<String>,
pub labels: HashMap<String, String>,
pub exposed_ports: Vec<String>,
pub tty: bool,
pub open_stdin: bool,
pub working_dir: Option<String>,
pub entrypoint: Vec<String>,
pub cmd: Vec<String>,
pub mounts: Vec<ContainerMount>,
pub publishes: Vec<PortPublish>,
pub restart_policy: Option<RestartPolicySpec>,
pub privileged: bool,
pub read_only_rootfs: bool,
pub extra_hosts: Vec<String>,
pub auto_remove: bool,
pub memory: Option<i64>,
pub nano_cpus: Option<i64>,
pub cap_add: Vec<String>,
pub network_mode: NetworkModeSpec,
}Expand description
Container creation spec translated from inspect output.
Fields§
§hostname: Option<String>Hostname.
domainname: Option<String>Domain name.
user: Option<String>User.
env: Vec<String>Environment variables.
labels: HashMap<String, String>Labels.
exposed_ports: Vec<String>Exposed ports.
tty: boolWhether tty mode is enabled.
open_stdin: boolWhether stdin should stay open.
working_dir: Option<String>Working directory.
entrypoint: Vec<String>Entrypoint argv.
cmd: Vec<String>Command argv.
mounts: Vec<ContainerMount>Mount definitions.
publishes: Vec<PortPublish>Port publish rules.
restart_policy: Option<RestartPolicySpec>Restart policy.
privileged: boolPrivileged mode.
read_only_rootfs: boolRead-only root filesystem.
extra_hosts: Vec<String>Extra hosts.
auto_remove: boolAuto-remove on exit.
memory: Option<i64>Memory limit in bytes, when one is set.
nano_cpus: Option<i64>CPU quota in units of 10^-9 CPUs, when one is set.
cap_add: Vec<String>Added Linux capabilities.
network_mode: NetworkModeSpecNetwork the container joins at create time.
Trait Implementations§
Source§impl Clone for ContainerSpec
impl Clone for ContainerSpec
Source§fn clone(&self) -> ContainerSpec
fn clone(&self) -> ContainerSpec
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ContainerSpec
impl Debug for ContainerSpec
Source§impl Default for ContainerSpec
impl Default for ContainerSpec
Source§fn default() -> ContainerSpec
fn default() -> ContainerSpec
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for ContainerSpec
impl<'de> Deserialize<'de> for ContainerSpec
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for ContainerSpec
impl PartialEq for ContainerSpec
Source§impl Serialize for ContainerSpec
impl Serialize for ContainerSpec
impl StructuralPartialEq for ContainerSpec
Auto Trait Implementations§
impl Freeze for ContainerSpec
impl RefUnwindSafe for ContainerSpec
impl Send for ContainerSpec
impl Sync for ContainerSpec
impl Unpin for ContainerSpec
impl UnsafeUnpin for ContainerSpec
impl UnwindSafe for ContainerSpec
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more