Skip to main content

tag_sync_tasks

Creates, updates, deletes or gets a tag_sync_task resource or lists tag_sync_tasks in a region

Overview

Nametag_sync_tasks
TypeResource
DescriptionSchema for ResourceGroups::TagSyncTask
Idawscc.resourcegroups.tag_sync_tasks

Fields

NameDatatypeDescription
groupstringThe Amazon resource name (ARN) or name of the application group for which you want to create a tag-sync task
group_arnstringThe Amazon resource name (ARN) of the ApplicationGroup for which the TagSyncTask is created
group_namestringThe Name of the application group for which the TagSyncTask is created
task_arnstringThe ARN of the TagSyncTask resource
tag_keystringThe tag key. Resources tagged with this tag key-value pair will be added to the application. If a resource with this tag is later untagged, the tag-sync task removes the resource from the application.
tag_valuestringThe tag value. Resources tagged with this tag key-value pair will be added to the application. If a resource with this tag is later untagged, the tag-sync task removes the resource from the application.
role_arnstringThe Amazon resource name (ARN) of the role assumed by the service to tag and untag resources on your behalf.
statusstringThe status of the TagSyncTask
regionstringAWS region.

For more information, see AWS::ResourceGroups::TagSyncTask.

Methods

NameResourceAccessible byRequired Params
create_resourcetag_sync_tasksINSERTGroup, TagKey, TagValue, RoleArn, region
delete_resourcetag_sync_tasksDELETEIdentifier, region
list_resourcestag_sync_tasks_list_onlySELECTregion
get_resourcetag_sync_tasksSELECTIdentifier, region

SELECT examples

Gets all properties from an individual tag_sync_task.

SELECT
region,
group,
group_arn,
group_name,
task_arn,
tag_key,
tag_value,
role_arn,
status
FROM awscc.resourcegroups.tag_sync_tasks
WHERE
region = 'us-east-1' AND
Identifier = '{{ task_arn }}';

INSERT example

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

/*+ create */
INSERT INTO awscc.resourcegroups.tag_sync_tasks (
Group,
TagKey,
TagValue,
RoleArn,
region
)
SELECT
'{{ group }}',
'{{ tag_key }}',
'{{ tag_value }}',
'{{ role_arn }}',
'{{ region }}';

DELETE example

/*+ delete */
DELETE FROM awscc.resourcegroups.tag_sync_tasks
WHERE
Identifier = '{{ task_arn }}' AND
region = 'us-east-1';

Permissions

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

resource-groups:StartTagSyncTask,
resource-groups:CreateGroup,
iam:PassRole