Skip to main content

task_sets

Creates, updates, deletes, gets or lists a task_sets resource.

Overview​

Nametask_sets
TypeResource
Idaws.ecs.task_sets

Fields​

The following fields are returned by SELECT queries:

NameDatatypeDescription
failuresarrayAny failures associated with the call.
task_setsarrayThe list of task sets described.

Methods​

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
describe_task_setsselectregionDescribes the task sets in the specified cluster and service. This is used when a service uses the EXTERNAL deployment controller type. For more information, see Amazon ECS Deployment Types in the Amazon Elastic Container Service Developer Guide.
create_task_setinsertregion, service, cluster, taskDefinitionCreate a task set in the specified cluster and service. This is used when a service uses the EXTERNAL deployment controller type. For more information, see Amazon ECS deployment types in the Amazon Elastic Container Service Developer Guide. On March 21, 2024, a change was made to resolve the task definition revision before authorization. When a task definition revision is not specified, authorization will occur using the latest revision of a task definition. For information about the maximum number of task sets and other quotas, see Amazon ECS service quotas in the Amazon Elastic Container Service Developer Guide.
update_task_setupdateregion, cluster, service, taskSet, scaleModifies a task set. This is used when a service uses the EXTERNAL deployment controller type. For more information, see Amazon ECS Deployment Types in the Amazon Elastic Container Service Developer Guide.
update_service_primary_task_setupdateregion, cluster, service, primaryTaskSetModifies which task set in a service is the primary task set. Any parameters that are updated on the primary task set in a service will transition to the service. This is used when a service uses the EXTERNAL deployment controller type. For more information, see Amazon ECS Deployment Types in the Amazon Elastic Container Service Developer Guide.
delete_task_setdeleteregionDeletes a specified task set within a service. This is used when a service uses the EXTERNAL deployment controller type. For more information, see Amazon ECS deployment types in the Amazon Elastic Container Service Developer Guide.

Parameters​

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
regionstringAWS region (default: us-east-1)

SELECT examples​

Describes the task sets in the specified cluster and service. This is used when a service uses the EXTERNAL deployment controller type. For more information, see Amazon ECS Deployment Types in the Amazon Elastic Container Service Developer Guide.

SELECT
failures,
task_sets
FROM aws.ecs.task_sets
WHERE region = '{{ region }}' -- required
;

INSERT examples​

Create a task set in the specified cluster and service. This is used when a service uses the EXTERNAL deployment controller type. For more information, see Amazon ECS deployment types in the Amazon Elastic Container Service Developer Guide. On March 21, 2024, a change was made to resolve the task definition revision before authorization. When a task definition revision is not specified, authorization will occur using the latest revision of a task definition. For information about the maximum number of task sets and other quotas, see Amazon ECS service quotas in the Amazon Elastic Container Service Developer Guide.

INSERT INTO aws.ecs.task_sets (
service,
cluster,
externalId,
taskDefinition,
networkConfiguration,
loadBalancers,
serviceRegistries,
launchType,
capacityProviderStrategy,
platformVersion,
scale,
clientToken,
tags,
region
)
SELECT
'{{ service }}' /* required */,
'{{ cluster }}' /* required */,
'{{ externalId }}',
'{{ taskDefinition }}' /* required */,
'{{ networkConfiguration }}',
'{{ loadBalancers }}',
'{{ serviceRegistries }}',
'{{ launchType }}',
'{{ capacityProviderStrategy }}',
'{{ platformVersion }}',
'{{ scale }}',
'{{ clientToken }}',
'{{ tags }}',
'{{ region }}'
RETURNING
task_set
;

UPDATE examples​

Modifies a task set. This is used when a service uses the EXTERNAL deployment controller type. For more information, see Amazon ECS Deployment Types in the Amazon Elastic Container Service Developer Guide.

UPDATE aws.ecs.task_sets
SET
cluster = '{{ cluster }}',
service = '{{ service }}',
taskSet = '{{ taskSet }}',
scale = '{{ scale }}'
WHERE
region = '{{ region }}' --required
AND cluster = '{{ cluster }}' --required
AND service = '{{ service }}' --required
AND taskSet = '{{ taskSet }}' --required
AND scale = '{{ scale }}' --required
RETURNING
task_set;

DELETE examples​

Deletes a specified task set within a service. This is used when a service uses the EXTERNAL deployment controller type. For more information, see Amazon ECS deployment types in the Amazon Elastic Container Service Developer Guide.

DELETE FROM aws.ecs.task_sets
WHERE region = '{{ region }}' --required
;