Skip to main content

resource_sets

Creates, updates, deletes or gets a resource_set resource or lists resource_sets in a region

Overview

Nameresource_sets
TypeResource
DescriptionCreates an AWS Firewall Manager resource set.
Idaws.fms.resource_sets

Fields

NameDatatypeDescription
idstringA Base62 ID
namestring
descriptionstring
resource_type_listarray
resourcesarray
tagsarray
regionstringAWS region.

Methods

NameAccessible byRequired Params
create_resourceINSERTName, ResourceTypeList, region
delete_resourceDELETEdata__Identifier, region
update_resourceUPDATEdata__Identifier, data__PatchDocument, region
list_resourcesSELECTregion
get_resourceSELECTdata__Identifier, region

SELECT examples

Gets all resource_sets in a region.

SELECT
region,
id,
name,
description,
resource_type_list,
resources,
tags
FROM aws.fms.resource_sets
WHERE region = 'us-east-1';

Gets all properties from an individual resource_set.

SELECT
region,
id,
name,
description,
resource_type_list,
resources,
tags
FROM aws.fms.resource_sets
WHERE region = 'us-east-1' AND data__Identifier = '<Id>';

INSERT example

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

/*+ create */
INSERT INTO aws.fms.resource_sets (
Name,
ResourceTypeList,
region
)
SELECT
'{{ Name }}',
'{{ ResourceTypeList }}',
'{{ region }}';

DELETE example

/*+ delete */
DELETE FROM aws.fms.resource_sets
WHERE data__Identifier = '<Id>'
AND region = 'us-east-1';

Permissions

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

Create

fms:PutResourceSet,
fms:BatchAssociateResource,
fms:ListResourceSetResources,
fms:TagResource

Update

fms:PutResourceSet,
fms:BatchAssociateResource,
fms:BatchDisassociateResource,
fms:GetResourceSet,
fms:ListResourceSetResources,
fms:TagResource,
fms:UntagResource,
fms:ListTagsForResource

Read

fms:GetResourceSet,
fms:ListResourceSetResources,
fms:ListTagsForResource

Delete

fms:DeleteResourceSet

List

fms:ListResourceSets