Skip to content

ContainerDetail

Source code in docs_src/capo_batch/types/container_detail.py
class ContainerDetail(TypedDict, closed=True):
    image: NotRequired["capo_batch.types.string.String"]
    """<p>The image used to start the container.</p>"""
    vcpus: NotRequired["capo_batch.types.integer.Integer"]
    """<p>The number of vCPUs reserved for the container. For jobs that run on Amazon EC2 resources, you can specify the vCPU requirement for the job using <code>resourceRequirements</code>, but you can't specify the vCPU requirements in both the <code>vcpus</code> and <code>resourceRequirements</code> object. This parameter maps to <code>CpuShares</code> in the <a href="https://docs.docker.com/engine/api/latest/#tag/Container/operation/ContainerCreate">Create a container</a> section of the <a href="https://docs.docker.com/engine/api/latest/">Docker Remote API</a> and the <code>--cpu-shares</code> option to <a href="https://docs.docker.com/engine/reference/run/">docker run</a>. Each vCPU is equivalent to 1,024 CPU shares. You must specify at least one vCPU. This is required but can be specified in several places. It must be specified for each node at least once.</p> <note> <p>This parameter isn't applicable to jobs that run on Fargate resources. For jobs that run on Fargate resources, you must specify the vCPU requirement for the job using <code>resourceRequirements</code>.</p> </note>"""
    memory: NotRequired["capo_batch.types.integer.Integer"]
    """<p>For jobs running on Amazon EC2 resources that didn't specify memory requirements using <code>resourceRequirements</code>, the number of MiB of memory reserved for the job. For other jobs, including all run on Fargate resources, see <code>resourceRequirements</code>.</p>"""
    command: NotRequired["capo_batch.types.string_list.StringList"]
    """<p>The command that's passed to the container.</p>"""
    job_role_arn: NotRequired["capo_batch.types.string.String"]
    """<p>The Amazon Resource Name (ARN) that's associated with the job when run.</p>"""
    execution_role_arn: NotRequired["capo_batch.types.string.String"]
    """<p>The Amazon Resource Name (ARN) of the execution role that Batch can assume. For more information, see <a href="https://docs.aws.amazon.com/batch/latest/userguide/execution-IAM-role.html">Batch execution IAM role</a> in the <i>Batch User Guide</i>.</p>"""
    volumes: NotRequired["capo_batch.types.volumes.Volumes"]
    """<p>A list of volumes that are associated with the job.</p>"""
    environment: NotRequired[
        "capo_batch.types.environment_variables.EnvironmentVariables"
    ]
    """<p>The environment variables to pass to a container.</p> <note> <p>Environment variables cannot start with "<code>AWS_BATCH</code>". This naming convention is reserved for variables that Batch sets.</p> </note>"""
    mount_points: NotRequired["capo_batch.types.mount_points.MountPoints"]
    """<p>The mount points for data volumes in your container.</p>"""
    readonly_root_filesystem: NotRequired["capo_batch.types.boolean.Boolean"]
    """<p>When this parameter is true, the container is given read-only access to its root file system. This parameter maps to <code>ReadonlyRootfs</code> in the <a href="https://docs.docker.com/engine/api/latest/#tag/Container/operation/ContainerCreate">Create a container</a> section of the <a href="https://docs.docker.com/engine/api/latest/">Docker Remote API</a> and the <code>--read-only</code> option to <a href="https://docs.docker.com/engine/reference/commandline/run/"> <code>docker run</code> </a>.</p>"""
    ulimits: NotRequired["capo_batch.types.ulimits.Ulimits"]
    """<p>A list of <code>ulimit</code> values to set in the container. This parameter maps to <code>Ulimits</code> in the <a href="https://docs.docker.com/engine/api/latest/#tag/Container/operation/ContainerCreate">Create a container</a> section of the <a href="https://docs.docker.com/engine/api/latest/">Docker Remote API</a> and the <code>--ulimit</code> option to <a href="https://docs.docker.com/engine/reference/run/">docker run</a>.</p> <note> <p>This parameter isn't applicable to jobs that are running on Fargate resources.</p> </note>"""
    privileged: NotRequired["capo_batch.types.boolean.Boolean"]
    """<p>When this parameter is true, the container is given elevated permissions on the host container instance (similar to the <code>root</code> user). The default value is <code>false</code>.</p> <note> <p>This parameter isn't applicable to jobs that are running on Fargate resources and shouldn't be provided, or specified as <code>false</code>.</p> </note>"""
    user: NotRequired["capo_batch.types.string.String"]
    """<p>The user name to use inside the container. This parameter maps to <code>User</code> in the <a href="https://docs.docker.com/engine/api/latest/#tag/Container/operation/ContainerCreate">Create a container</a> section of the <a href="https://docs.docker.com/engine/api/latest/">Docker Remote API</a> and the <code>--user</code> option to <a href="https://docs.docker.com/engine/reference/run/">docker run</a>.</p>"""
    exit_code: NotRequired["capo_batch.types.integer.Integer"]
    """<p>The exit code returned upon completion.</p>"""
    reason: NotRequired["capo_batch.types.string.String"]
    """<p>A short (255 max characters) human-readable string to provide additional details for a running or stopped container.</p>"""
    container_instance_arn: NotRequired["capo_batch.types.string.String"]
    """<p>The Amazon Resource Name (ARN) of the container instance that the container is running on.</p>"""
    task_arn: NotRequired["capo_batch.types.string.String"]
    """<p>The Amazon Resource Name (ARN) of the Amazon ECS task that's associated with the container job. Each container attempt receives a task ARN when they reach the <code>STARTING</code> status.</p>"""
    log_stream_name: NotRequired["capo_batch.types.string.String"]
    """<p>The name of the Amazon CloudWatch Logs log stream that's associated with the container. The log group for Batch jobs is <code>/aws/batch/job</code>. Each container attempt receives a log stream name when they reach the <code>RUNNING</code> status.</p>"""
    instance_type: NotRequired["capo_batch.types.string.String"]
    """<p>The instance type of the underlying host infrastructure of a multi-node parallel job.</p> <note> <p>This parameter isn't applicable to jobs that are running on Fargate resources.</p> </note>"""
    network_interfaces: NotRequired[
        "capo_batch.types.network_interface_list.NetworkInterfaceList"
    ]
    """<p>The network interfaces that are associated with the job.</p>"""
    resource_requirements: NotRequired[
        "capo_batch.types.resource_requirements.ResourceRequirements"
    ]
    """<p>The type and amount of resources to assign to a container. The supported resources include <code>GPU</code>, <code>MEMORY</code>, and <code>VCPU</code>.</p>"""
    linux_parameters: NotRequired["capo_batch.types.linux_parameters.LinuxParameters"]
    """<p>Linux-specific modifications that are applied to the container, such as details for device mappings.</p>"""
    log_configuration: NotRequired[
        "capo_batch.types.log_configuration.LogConfiguration"
    ]
    """<p>The log configuration specification for the container.</p> <p>This parameter maps to <code>LogConfig</code> in the <a href="https://docs.docker.com/engine/api/latest/#tag/Container/operation/ContainerCreate">Create a container</a> section of the <a href="https://docs.docker.com/engine/api/latest/">Docker Remote API</a> and the <code>--log-driver</code> option to <a href="https://docs.docker.com/engine/reference/run/">docker run</a>. By default, containers use the same logging driver that the Docker daemon uses. However, the container might use a different logging driver than the Docker daemon by specifying a log driver with this parameter in the container definition. To use a different logging driver for a container, the log system must be configured properly on the container instance. Or, alternatively, it must be configured on a different log server for remote logging options. For more information on the options for different supported log drivers, see <a href="https://docs.docker.com/engine/admin/logging/overview/">Configure logging drivers</a> in the Docker documentation.</p> <note> <p>Batch currently supports a subset of the logging drivers available to the Docker daemon (shown in the <a href="https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties-logconfiguration.html">LogConfiguration</a> data type). Additional log drivers might be available in future releases of the Amazon ECS container agent.</p> </note> <p>This parameter requires version 1.18 of the Docker Remote API or greater on your container instance. To check the Docker Remote API version on your container instance, log in to your container instance and run the following command: <code>sudo docker version | grep "Server API version"</code> </p> <note> <p>The Amazon ECS container agent running on a container instance must register the logging drivers available on that instance with the <code>ECS_AVAILABLE_LOGGING_DRIVERS</code> environment variable before containers placed on that instance can use these log configuration options. For more information, see <a href="https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ecs-agent-config.html">Amazon ECS container agent configuration</a> in the <i>Amazon Elastic Container Service Developer Guide</i>.</p> </note>"""
    secrets: NotRequired["capo_batch.types.secret_list.SecretList"]
    """<p>The secrets to pass to the container. For more information, see <a href="https://docs.aws.amazon.com/batch/latest/userguide/specifying-sensitive-data.html">Specifying sensitive data</a> in the <i>Batch User Guide</i>.</p>"""
    network_configuration: NotRequired[
        "capo_batch.types.network_configuration.NetworkConfiguration"
    ]
    """<p>The network configuration for jobs that are running on Fargate resources. Jobs that are running on Amazon EC2 resources must not specify this parameter.</p>"""
    fargate_platform_configuration: NotRequired[
        "capo_batch.types.fargate_platform_configuration.FargatePlatformConfiguration"
    ]
    """<p>The platform configuration for jobs that are running on Fargate resources. Jobs that are running on Amazon EC2 resources must not specify this parameter.</p>"""
    ephemeral_storage: NotRequired[
        "capo_batch.types.ephemeral_storage.EphemeralStorage"
    ]
    """<p>The amount of ephemeral storage allocated for the task. This parameter is used to expand the total amount of ephemeral storage available, beyond the default amount, for tasks hosted on Fargate.</p>"""
    runtime_platform: NotRequired["capo_batch.types.runtime_platform.RuntimePlatform"]
    """<p>An object that represents the compute environment architecture for Batch jobs on Fargate.</p>"""
    repository_credentials: NotRequired[
        "capo_batch.types.repository_credentials.RepositoryCredentials"
    ]
    """<p>The private repository authentication credentials to use.</p>"""
    enable_execute_command: NotRequired["capo_batch.types.boolean.Boolean"]
    """<p>Determines whether execute command functionality is turned on for this task. If <code>true</code>, execute command functionality is turned on all the containers in the task.</p>"""

command instance-attribute

command: NotRequired[StringList]

The command that's passed to the container.

container_instance_arn instance-attribute

container_instance_arn: NotRequired[String]

The Amazon Resource Name (ARN) of the container instance that the container is running on.

enable_execute_command instance-attribute

enable_execute_command: NotRequired[Boolean]

Determines whether execute command functionality is turned on for this task. If true, execute command functionality is turned on all the containers in the task.

environment instance-attribute

environment: NotRequired[EnvironmentVariables]

The environment variables to pass to a container.

Environment variables cannot start with "AWS_BATCH". This naming convention is reserved for variables that Batch sets.

ephemeral_storage instance-attribute

ephemeral_storage: NotRequired[EphemeralStorage]

The amount of ephemeral storage allocated for the task. This parameter is used to expand the total amount of ephemeral storage available, beyond the default amount, for tasks hosted on Fargate.

execution_role_arn instance-attribute

execution_role_arn: NotRequired[String]

The Amazon Resource Name (ARN) of the execution role that Batch can assume. For more information, see Batch execution IAM role in the Batch User Guide.

exit_code instance-attribute

exit_code: NotRequired[Integer]

The exit code returned upon completion.

fargate_platform_configuration instance-attribute

fargate_platform_configuration: NotRequired[FargatePlatformConfiguration]

The platform configuration for jobs that are running on Fargate resources. Jobs that are running on Amazon EC2 resources must not specify this parameter.

image instance-attribute

image: NotRequired[String]

The image used to start the container.

instance_type instance-attribute

instance_type: NotRequired[String]

The instance type of the underlying host infrastructure of a multi-node parallel job.

This parameter isn't applicable to jobs that are running on Fargate resources.

job_role_arn instance-attribute

job_role_arn: NotRequired[String]

The Amazon Resource Name (ARN) that's associated with the job when run.

linux_parameters instance-attribute

linux_parameters: NotRequired[LinuxParameters]

Linux-specific modifications that are applied to the container, such as details for device mappings.

log_configuration instance-attribute

log_configuration: NotRequired[LogConfiguration]

The log configuration specification for the container.

This parameter maps to LogConfig in the Create a container section of the Docker Remote API and the --log-driver option to docker run. By default, containers use the same logging driver that the Docker daemon uses. However, the container might use a different logging driver than the Docker daemon by specifying a log driver with this parameter in the container definition. To use a different logging driver for a container, the log system must be configured properly on the container instance. Or, alternatively, it must be configured on a different log server for remote logging options. For more information on the options for different supported log drivers, see Configure logging drivers in the Docker documentation.

Batch currently supports a subset of the logging drivers available to the Docker daemon (shown in the LogConfiguration data type). Additional log drivers might be available in future releases of the Amazon ECS container agent.

This parameter requires version 1.18 of the Docker Remote API or greater on your container instance. To check the Docker Remote API version on your container instance, log in to your container instance and run the following command: sudo docker version | grep "Server API version"

The Amazon ECS container agent running on a container instance must register the logging drivers available on that instance with the ECS_AVAILABLE_LOGGING_DRIVERS environment variable before containers placed on that instance can use these log configuration options. For more information, see Amazon ECS container agent configuration in the Amazon Elastic Container Service Developer Guide.

log_stream_name instance-attribute

log_stream_name: NotRequired[String]

The name of the Amazon CloudWatch Logs log stream that's associated with the container. The log group for Batch jobs is /aws/batch/job. Each container attempt receives a log stream name when they reach the RUNNING status.

memory instance-attribute

memory: NotRequired[Integer]

For jobs running on Amazon EC2 resources that didn't specify memory requirements using resourceRequirements, the number of MiB of memory reserved for the job. For other jobs, including all run on Fargate resources, see resourceRequirements.

mount_points instance-attribute

mount_points: NotRequired[MountPoints]

The mount points for data volumes in your container.

network_configuration instance-attribute

network_configuration: NotRequired[NetworkConfiguration]

The network configuration for jobs that are running on Fargate resources. Jobs that are running on Amazon EC2 resources must not specify this parameter.

network_interfaces instance-attribute

network_interfaces: NotRequired[NetworkInterfaceList]

The network interfaces that are associated with the job.

privileged instance-attribute

privileged: NotRequired[Boolean]

When this parameter is true, the container is given elevated permissions on the host container instance (similar to the root user). The default value is false.

This parameter isn't applicable to jobs that are running on Fargate resources and shouldn't be provided, or specified as false.

readonly_root_filesystem instance-attribute

readonly_root_filesystem: NotRequired[Boolean]

When this parameter is true, the container is given read-only access to its root file system. This parameter maps to ReadonlyRootfs in the Create a container section of the Docker Remote API and the --read-only option to docker run .

reason instance-attribute

reason: NotRequired[String]

A short (255 max characters) human-readable string to provide additional details for a running or stopped container.

repository_credentials instance-attribute

repository_credentials: NotRequired[RepositoryCredentials]

The private repository authentication credentials to use.

resource_requirements instance-attribute

resource_requirements: NotRequired[ResourceRequirements]

The type and amount of resources to assign to a container. The supported resources include GPU, MEMORY, and VCPU.

runtime_platform instance-attribute

runtime_platform: NotRequired[RuntimePlatform]

An object that represents the compute environment architecture for Batch jobs on Fargate.

secrets instance-attribute

secrets: NotRequired[SecretList]

The secrets to pass to the container. For more information, see Specifying sensitive data in the Batch User Guide.

task_arn instance-attribute

task_arn: NotRequired[String]

The Amazon Resource Name (ARN) of the Amazon ECS task that's associated with the container job. Each container attempt receives a task ARN when they reach the STARTING status.

ulimits instance-attribute

ulimits: NotRequired[Ulimits]

A list of ulimit values to set in the container. This parameter maps to Ulimits in the Create a container section of the Docker Remote API and the --ulimit option to docker run.

This parameter isn't applicable to jobs that are running on Fargate resources.

user instance-attribute

user: NotRequired[String]

The user name to use inside the container. This parameter maps to User in the Create a container section of the Docker Remote API and the --user option to docker run.

vcpus instance-attribute

vcpus: NotRequired[Integer]

The number of vCPUs reserved for the container. For jobs that run on Amazon EC2 resources, you can specify the vCPU requirement for the job using resourceRequirements, but you can't specify the vCPU requirements in both the vcpus and resourceRequirements object. This parameter maps to CpuShares in the Create a container section of the Docker Remote API and the --cpu-shares option to docker run. Each vCPU is equivalent to 1,024 CPU shares. You must specify at least one vCPU. This is required but can be specified in several places. It must be specified for each node at least once.

This parameter isn't applicable to jobs that run on Fargate resources. For jobs that run on Fargate resources, you must specify the vCPU requirement for the job using resourceRequirements.

volumes instance-attribute

volumes: NotRequired[Volumes]

A list of volumes that are associated with the job.