Struct aws_sdk_batch::types::TaskContainerOverrides
source · #[non_exhaustive]pub struct TaskContainerOverrides {
pub command: Option<Vec<String>>,
pub environment: Option<Vec<KeyValuePair>>,
pub name: Option<String>,
pub resource_requirements: Option<Vec<ResourceRequirement>>,
}
Expand description
The overrides that should be sent to a container.
For information about using Batch overrides when you connect event sources to targets, see BatchContainerOverrides.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. }
syntax; cannot be matched against without a wildcard ..
; and struct update syntax will not work.command: Option<Vec<String>>
The command to send to the container that overrides the default command from the Docker image or the job definition.
This parameter can't contain an empty string.
environment: Option<Vec<KeyValuePair>>
The environment variables to send to the container. You can add new environment variables, which are added to the container at launch, or you can override the existing environment variables from the Docker image or the job definition.
Environment variables cannot start with AWS_BATCH
. This naming convention is reserved for variables that Batch sets.
name: Option<String>
A pointer to the container that you want to override. The container's name provides a unique identifier for the container being used.
resource_requirements: Option<Vec<ResourceRequirement>>
The type and amount of resources to assign to a container. This overrides the settings in the job definition. The supported resources include GPU
, MEMORY
, and VCPU
.
Implementations§
source§impl TaskContainerOverrides
impl TaskContainerOverrides
sourcepub fn command(&self) -> &[String]
pub fn command(&self) -> &[String]
The command to send to the container that overrides the default command from the Docker image or the job definition.
This parameter can't contain an empty string.
If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use .command.is_none()
.
sourcepub fn environment(&self) -> &[KeyValuePair]
pub fn environment(&self) -> &[KeyValuePair]
The environment variables to send to the container. You can add new environment variables, which are added to the container at launch, or you can override the existing environment variables from the Docker image or the job definition.
Environment variables cannot start with AWS_BATCH
. This naming convention is reserved for variables that Batch sets.
If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use .environment.is_none()
.
sourcepub fn name(&self) -> Option<&str>
pub fn name(&self) -> Option<&str>
A pointer to the container that you want to override. The container's name provides a unique identifier for the container being used.
sourcepub fn resource_requirements(&self) -> &[ResourceRequirement]
pub fn resource_requirements(&self) -> &[ResourceRequirement]
The type and amount of resources to assign to a container. This overrides the settings in the job definition. The supported resources include GPU
, MEMORY
, and VCPU
.
If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use .resource_requirements.is_none()
.
source§impl TaskContainerOverrides
impl TaskContainerOverrides
sourcepub fn builder() -> TaskContainerOverridesBuilder
pub fn builder() -> TaskContainerOverridesBuilder
Creates a new builder-style object to manufacture TaskContainerOverrides
.
Trait Implementations§
source§impl Clone for TaskContainerOverrides
impl Clone for TaskContainerOverrides
source§fn clone(&self) -> TaskContainerOverrides
fn clone(&self) -> TaskContainerOverrides
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for TaskContainerOverrides
impl Debug for TaskContainerOverrides
source§impl PartialEq for TaskContainerOverrides
impl PartialEq for TaskContainerOverrides
source§fn eq(&self, other: &TaskContainerOverrides) -> bool
fn eq(&self, other: &TaskContainerOverrides) -> bool
self
and other
values to be equal, and is used
by ==
.