fuota_tasks
Creates, updates, deletes or gets a fuota_task resource or lists fuota_tasks in a region
Overview
| Name | fuota_tasks |
| Type | Resource |
| Description | Create and manage FUOTA tasks. |
| Id | awscc.iotwireless.fuota_tasks |
Fields
- get (all properties)
- list (identifiers only)
| Name | Datatype | Description |
|---|---|---|
name | string | Name of FUOTA task |
description | string | FUOTA task description |
lo_ra_wan | object | FUOTA task LoRaWAN |
firmware_update_image | string | FUOTA task firmware update image binary S3 link |
firmware_update_role | string | FUOTA task firmware IAM role for reading S3 |
arn | string | FUOTA task arn. Returned after successful create. |
id | string | FUOTA task id. Returned after successful create. |
tags | array | A list of key-value pairs that contain metadata for the FUOTA task. |
fuota_task_status | string | FUOTA task status. Returned after successful read. |
associate_wireless_device | string | Wireless device to associate. Only for update request. |
disassociate_wireless_device | string | Wireless device to disassociate. Only for update request. |
associate_multicast_group | string | Multicast group to associate. Only for update request. |
disassociate_multicast_group | string | Multicast group to disassociate. Only for update request. |
region | string | AWS region. |
| Name | Datatype | Description |
|---|---|---|
id | string | FUOTA task id. Returned after successful create. |
region | string | AWS region. |
For more information, see AWS::IoTWireless::FuotaTask.
Methods
| Name | Resource | Accessible by | Required Params |
|---|---|---|---|
create_resource | fuota_tasks | INSERT | LoRaWAN, FirmwareUpdateImage, FirmwareUpdateRole, region |
delete_resource | fuota_tasks | DELETE | Identifier, region |
update_resource | fuota_tasks | UPDATE | Identifier, PatchDocument, region |
list_resources | fuota_tasks_list_only | SELECT | region |
get_resource | fuota_tasks | SELECT | Identifier, region |
SELECT examples
- get (all properties)
- list (identifiers only)
Gets all properties from an individual fuota_task.
SELECT
region,
name,
description,
lo_ra_wan,
firmware_update_image,
firmware_update_role,
arn,
id,
tags,
fuota_task_status,
associate_wireless_device,
disassociate_wireless_device,
associate_multicast_group,
disassociate_multicast_group
FROM awscc.iotwireless.fuota_tasks
WHERE
region = '{{ region }}' AND
Identifier = '{{ id }}';
Lists all fuota_tasks in a region.
SELECT
region,
id
FROM awscc.iotwireless.fuota_tasks_list_only
WHERE
region = '{{ region }}';
INSERT example
Use the following StackQL query and manifest file to create a new fuota_task resource, using stack-deploy.
- Required Properties
- All Properties
- Manifest
/*+ create */
INSERT INTO awscc.iotwireless.fuota_tasks (
LoRaWAN,
FirmwareUpdateImage,
FirmwareUpdateRole,
region
)
SELECT
'{{ lo_ra_wan }}',
'{{ firmware_update_image }}',
'{{ firmware_update_role }}',
'{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
/*+ create */
INSERT INTO awscc.iotwireless.fuota_tasks (
Name,
Description,
LoRaWAN,
FirmwareUpdateImage,
FirmwareUpdateRole,
Tags,
AssociateWirelessDevice,
DisassociateWirelessDevice,
AssociateMulticastGroup,
DisassociateMulticastGroup,
region
)
SELECT
'{{ name }}',
'{{ description }}',
'{{ lo_ra_wan }}',
'{{ firmware_update_image }}',
'{{ firmware_update_role }}',
'{{ tags }}',
'{{ associate_wireless_device }}',
'{{ disassociate_wireless_device }}',
'{{ associate_multicast_group }}',
'{{ disassociate_multicast_group }}',
'{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
version: 1
name: stack name
description: stack description
providers:
- aws
globals:
- name: region
value: '{{ vars.AWS_REGION }}'
resources:
- name: fuota_task
props:
- name: name
value: '{{ name }}'
- name: description
value: '{{ description }}'
- name: lo_ra_wan
value:
rf_region: '{{ rf_region }}'
dl_class: '{{ dl_class }}'
number_of_devices_requested: '{{ number_of_devices_requested }}'
number_of_devices_in_group: '{{ number_of_devices_in_group }}'
- name: firmware_update_image
value: '{{ firmware_update_image }}'
- name: firmware_update_role
value: '{{ firmware_update_role }}'
- name: tags
value:
- key: '{{ key }}'
value: '{{ value }}'
- name: associate_wireless_device
value: '{{ associate_wireless_device }}'
- name: disassociate_wireless_device
value: '{{ disassociate_wireless_device }}'
- name: associate_multicast_group
value: '{{ associate_multicast_group }}'
- name: disassociate_multicast_group
value: '{{ disassociate_multicast_group }}'
UPDATE example
Use the following StackQL query and manifest file to update a fuota_task resource, using stack-deploy.
/*+ update */
UPDATE awscc.iotwireless.fuota_tasks
SET PatchDocument = string('{{ {
"Name": name,
"Description": description,
"FirmwareUpdateImage": firmware_update_image,
"FirmwareUpdateRole": firmware_update_role,
"Tags": tags,
"AssociateWirelessDevice": associate_wireless_device,
"DisassociateWirelessDevice": disassociate_wireless_device,
"AssociateMulticastGroup": associate_multicast_group,
"DisassociateMulticastGroup": disassociate_multicast_group
} | generate_patch_document }}')
WHERE
region = '{{ region }}' AND
Identifier = '{{ id }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
DELETE example
/*+ delete */
DELETE FROM awscc.iotwireless.fuota_tasks
WHERE
Identifier = '{{ id }}' AND
region = '{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
Additional Parameters
Mutable resources in the Cloud Control provider support additional optional parameters which can be supplied with INSERT, UPDATE, or DELETE operations. These include:
| Parameter | Description |
|---|---|
ClientToken | A unique identifier to ensure the idempotency of the resource request.This allows the provider to accurately distinguish between retries and new requests.A client token is valid for 36 hours once used. After that, a resource request with the same client token is treated as a new request. If you do not specify a client token, one is generated for inclusion in the request. |
RoleArn | The ARN of the IAM role used to perform this resource operation.The role specified must have the permissions required for this operation.If you do not specify a role, a temporary session is created using your AWS user credentials. |
TypeVersionId | For private resource types, the type version to use in this resource operation.If you do not specify a resource version, the default version is used. |
Permissions
To operate on the fuota_tasks resource, the following permissions are required:
- Create
- Read
- Update
- Delete
- List
iotwireless:CreateFuotaTask,
iotwireless:TagResource,
iam:GetRole,
iam:PassRole
iotwireless:GetFuotaTask,
iotwireless:ListTagsForResource
iam:PassRole,
iotwireless:UpdateFuotaTask,
iotwireless:GetFuotaTask,
iotwireless:TagResource,
iotwireless:UntagResource,
iotwireless:AssociateMulticastGroupWithFuotaTask,
iotwireless:DisassociateMulticastGroupFromFuotaTask,
iotwireless:AssociateWirelessDeviceWithFuotaTask,
iotwireless:DisassociateWirelessDeviceFromFuotaTask
iotwireless:DeleteFuotaTask
iotwireless:ListFuotaTasks,
iotwireless:ListTagsForResource