Skip to main content

task_definitions

Creates, updates, deletes or gets a task_definition resource or lists task_definitions in a region

Overview

Nametask_definitions
TypeResource
DescriptionCreates a gateway task definition.
Idawscc.iotwireless.task_definitions

Fields

NameDatatypeDescription
namestringThe name of the new resource.
auto_create_tasksbooleanWhether to automatically create tasks using this task definition for all gateways with the specified current version. If false, the task must me created by calling CreateWirelessGatewayTask.
updateobjectInformation about the gateways to update.
lo_ra_wan_update_gateway_task_entryobjectThe list of task definitions.
idstringThe ID of the new wireless gateway task definition
task_definition_typestringA filter to list only the wireless gateway task definitions that use this task definition type
arnstringTaskDefinition arn. Returned after successful create.
tagsarrayA list of key-value pairs that contain metadata for the destination.
regionstringAWS region.

For more information, see AWS::IoTWireless::TaskDefinition.

Methods

NameResourceAccessible byRequired Params
create_resourcetask_definitionsINSERTAutoCreateTasks, region
delete_resourcetask_definitionsDELETEIdentifier, region
update_resourcetask_definitionsUPDATEIdentifier, PatchDocument, region
list_resourcestask_definitions_list_onlySELECTregion
get_resourcetask_definitionsSELECTIdentifier, region

SELECT examples

Gets all properties from an individual task_definition.

SELECT
region,
name,
auto_create_tasks,
update,
lo_ra_wan_update_gateway_task_entry,
id,
task_definition_type,
arn,
tags
FROM awscc.iotwireless.task_definitions
WHERE
region = 'us-east-1' AND
Identifier = '{{ id }}';

INSERT example

Use the following StackQL query and manifest file to create a new task_definition resource, using stack-deploy.

/*+ create */
INSERT INTO awscc.iotwireless.task_definitions (
AutoCreateTasks,
region
)
SELECT
'{{ auto_create_tasks }}',
'{{ region }}';

UPDATE example

Use the following StackQL query and manifest file to update a task_definition resource, using stack-deploy.

/*+ update */
UPDATE awscc.iotwireless.task_definitions
SET PatchDocument = string('{{ {
"Name": name,
"AutoCreateTasks": auto_create_tasks,
"Update": update,
"LoRaWANUpdateGatewayTaskEntry": lo_ra_wan_update_gateway_task_entry,
"TaskDefinitionType": task_definition_type,
"Tags": tags
} | generate_patch_document }}')
WHERE
region = '{{ region }}' AND
Identifier = '{{ id }}';

DELETE example

/*+ delete */
DELETE FROM awscc.iotwireless.task_definitions
WHERE
Identifier = '{{ id }}' AND
region = 'us-east-1';

Permissions

To operate on the task_definitions resource, the following permissions are required:

iotwireless:CreateWirelessGatewayTaskDefinition,
iotwireless:TagResource,
iam:GetRole,
iam:PassRole