Amazon Elastic Container Service (Amazon ECS) is a highly scalable, fast, container management service that makes it easy to run, stop, and manage Docker containers on a cluster. You can host your cluster on a serverless infrastructure that is managed by Amazon ECS by launching your services or tasks using the Fargate launch type. For more control, you can host your tasks on a cluster of Amazon Elastic Compute Cloud (Amazon EC2) instances that you manage by using the EC2 launch type. For more information about launch types, see Amazon ECS Launch Types.
Amazon ECS lets you launch and stop container-based applications with simple API calls, allows you to get the state of your cluster from a centralized service, and gives you access to many familiar Amazon EC2 features.
You can use Amazon ECS to schedule the placement of containers across your cluster based on your resource needs, isolation policies, and availability requirements. Amazon ECS eliminates the need for you to operate your own cluster management and configuration management systems or worry about scaling your management infrastructure.
An object representing a container instance or task attachment.
An object representing a change in state for a task attachment.
An attribute is a name-value pair associated with an Amazon ECS object. Attributes enable you to extend the Amazon ECS data model by adding custom metadata to your resources. For more information, see Attributes in the Amazon Elastic Container Service Developer Guide.
The details of the Auto Scaling group for the capacity provider.
An object representing the networking details for a task or service.
The details of a capacity provider.
The details of a capacity provider strategy.
A regional grouping of one or more container instances on which you can run task requests. Each account receives a default cluster the first time you use the Amazon ECS service, but you may also create other clusters. Clusters may contain more than one instance type simultaneously.
The settings to use when creating a cluster. This parameter is used to enable CloudWatch Container Insights for a cluster.
A Docker container that is part of a task.
Container definitions are used in task definitions to describe the different containers that are launched as part of a task.
The dependencies defined for container startup and shutdown. A container can contain multiple dependencies. When a dependency is defined for container startup, for container shutdown it is reversed.
Your Amazon ECS container instances require at least version 1.26.0 of the container agent to enable container dependencies. However, we recommend using the latest container agent version. For information about checking your agent version and updating to the latest version, see Updating the Amazon ECS Container Agent in the Amazon Elastic Container Service Developer Guide. If you are using an Amazon ECS-optimized Linux AMI, your instance needs at least version 1.26.0-1 of the
For tasks using the Fargate launch type, this parameter requires that the task or service uses platform version 1.3.0 or later.
An EC2 instance that is running the Amazon ECS agent and has been registered with a cluster.
The overrides that should be sent to a container. An empty container override can be passed in. An example of an empty container override would be
An object representing a change in state for a container.
The details of an Amazon ECS service deployment. This is used only when a service uses the
Optional deployment parameters that control how many tasks run during a deployment and the ordering of stopping and starting tasks.
The deployment controller to use for the service. For more information, see Amazon ECS Deployment Types in the Amazon Elastic Container Service Developer Guide.
An object representing a container instance host device.
This parameter is specified when you are using Docker volumes. Docker volumes are only supported when you are using the EC2 launch type. Windows containers only support the use of the
The authorization configuration details for the Amazon EFS file system.
This parameter is specified when you are using an Amazon Elastic File System file system for task storage. For more information, see Amazon EFS Volumes in the Amazon Elastic Container Service Developer Guide.
A client for the Amazon ECS API.
A list of files containing the environment variables to pass to a container. You can specify up to ten environment files. The file must have a
If there are environment variables specified using the
This field is not valid for containers in tasks using the Fargate launch type.
A failed resource.
The FireLens configuration for the container. This is used to specify and configure a log router for container logs. For more information, see Custom Log Routing in the Amazon Elastic Container Service Developer Guide.
An object representing a container health check. Health check parameters that are specified in a container definition override any Docker health checks that exist in the container image (such as those specified in a parent image or from the image's Dockerfile).
You can view the health status of both individual containers and a task with the DescribeTasks API operation or when viewing the task details in the console.
The following describes the possible
The following describes the possible
If a task is run manually, and not as part of a service, the task will continue its lifecycle regardless of its health status. For tasks that are part of a service, if the task reports as unhealthy then the task will be stopped and the service scheduler will replace it.
The following are notes about container health check support:
Hostnames and IP address entries that are added to the
Details on a container instance bind mount host volume.
Details on a Elastic Inference accelerator. For more information, see Working with Amazon Elastic Inference on Amazon ECS in the Amazon Elastic Container Service Developer Guide.
Details on an Elastic Inference accelerator task override. This parameter is used to override the Elastic Inference accelerator specified in the task definition. For more information, see Working with Amazon Elastic Inference on Amazon ECS in the Amazon Elastic Container Service Developer Guide.
The Linux capabilities for the container that are added to or dropped from the default configuration provided by Docker. For more information on the default capabilities and the non-default available capabilities, see Runtime privilege and Linux capabilities in the Docker run reference. For more detailed information on these Linux capabilities, see the capabilities(7) Linux manual page.
A key-value pair object.
Linux-specific options that are applied to the container, such as Linux KernelCapabilities.
The load balancer configuration to use with a service or task set.
For specific notes and restrictions regarding the use of load balancers with services and task sets, see the CreateService and CreateTaskSet actions.
The log configuration specification for the container.
This parameter maps to
The following should be noted when specifying a log configuration for your containers:
The managed scaling settings for the Auto Scaling group capacity provider.
When managed scaling is enabled, Amazon ECS manages the scale-in and scale-out actions of the Auto Scaling group. Amazon ECS manages a target tracking scaling policy using an Amazon ECS-managed CloudWatch metric with the specified
If managed scaling is disabled, the user must manage the scaling of the Auto Scaling group.
Details on a volume mount point that is used in a container definition.
Details on the network bindings between a container and its host container instance. After a task reaches the
An object representing the network configuration for a task or service.
An object representing the elastic network interface for tasks that use the
An object representing a constraint on task placement. For more information, see Task Placement Constraints in the Amazon Elastic Container Service Developer Guide.
If you are using the Fargate launch type, task placement constraints are not supported.
The task placement strategy for a task or service. For more information, see Task Placement Strategies in the Amazon Elastic Container Service Developer Guide.
The devices that are available on the container instance. The only supported device type is a GPU.
Port mappings allow containers to access ports on the host container instance to send or receive traffic. Port mappings are specified as part of the container definition.
If you are using containers in a task with the
After a task reaches the
The configuration details for the App Mesh proxy.
For tasks using the EC2 launch type, the container instances require at least version 1.26.0 of the container agent and at least version 1.26.0-1 of the
For tasks using the Fargate launch type, the task or service requires platform version 1.3.0 or later.
The repository credentials for private registry authentication.
Describes the resources available for a container instance.
The type and amount of a resource to assign to a container. The supported resource types are GPUs and Elastic Inference accelerators. For more information, see Working with GPUs on Amazon ECS or Working with Amazon Elastic Inference on Amazon ECS in the Amazon Elastic Container Service Developer Guide
A floating-point percentage of the desired number of tasks to place and keep running in the task set.
An object representing the secret to expose to your container. Secrets can be exposed to a container in the following ways:
For more information, see Specifying Sensitive Data in the Amazon Elastic Container Service Developer Guide.
Details on a service within a cluster
Details on an event associated with a service.
Details of the service registry.
The current account setting for a resource.
It is not recommended that you specify network-related
The metadata that you apply to a resource to help you categorize and organize them. Each tag consists of a key and an optional value, both of which you define.
The following basic restrictions apply to tags:
Details on a task in a cluster.
The details of a task definition which describes the container and volume definitions of an Amazon Elastic Container Service task. You can specify which Docker images to use, the required resources, and other configurations related to launching the task definition through an Amazon ECS service or task.
An object representing a constraint on task placement in the task definition. For more information, see Task Placement Constraints in the Amazon Elastic Container Service Developer Guide.
If you are using the Fargate launch type, task placement constraints are not supported.
The overrides associated with a task.
Information about a set of Amazon ECS tasks in either an AWS CodeDeploy or an
The container path, mount options, and size of the tmpfs mount.
The Docker and Amazon ECS container agent version information about a container instance.
A data volume used in a task definition. For tasks that use Amazon Elastic File System (Amazon EFS) file storage, specify an
Details on a data volume from another container in the same task definition.
Errors returned by CreateCapacityProvider
Errors returned by CreateCluster
Errors returned by CreateService
Errors returned by CreateTaskSet
Errors returned by DeleteAccountSetting
Errors returned by DeleteAttributes
Errors returned by DeleteCapacityProvider
Errors returned by DeleteCluster
Errors returned by DeleteService
Errors returned by DeleteTaskSet
Errors returned by DeregisterContainerInstance
Errors returned by DeregisterTaskDefinition
Errors returned by DescribeCapacityProviders
Errors returned by DescribeClusters
Errors returned by DescribeContainerInstances
Errors returned by DescribeServices
Errors returned by DescribeTaskDefinition
Errors returned by DescribeTaskSets
Errors returned by DescribeTasks
Errors returned by DiscoverPollEndpoint
Errors returned by ListAccountSettings
Errors returned by ListAttributes
Errors returned by ListClusters
Errors returned by ListContainerInstances
Errors returned by ListServices
Errors returned by ListTagsForResource
Errors returned by ListTaskDefinitionFamilies
Errors returned by ListTaskDefinitions
Errors returned by ListTasks
Errors returned by PutAccountSettingDefault
Errors returned by PutAccountSetting
Errors returned by PutAttributes
Errors returned by PutClusterCapacityProviders
Errors returned by RegisterContainerInstance
Errors returned by RegisterTaskDefinition
Errors returned by RunTask
Errors returned by StartTask
Errors returned by StopTask
Errors returned by SubmitAttachmentStateChanges
Errors returned by SubmitContainerStateChange
Errors returned by SubmitTaskStateChange
Errors returned by TagResource
Errors returned by UntagResource
Errors returned by UpdateClusterSettings
Errors returned by UpdateContainerAgent
Errors returned by UpdateContainerInstancesState
Errors returned by UpdateService
Errors returned by UpdateServicePrimaryTaskSet
Errors returned by UpdateTaskSet
Trait representing the capabilities of the Amazon ECS API. Amazon ECS clients implement this trait.