Skip to main content

components

Creates, updates, deletes or gets a component resource or lists components in a region

Overview

Namecomponents
TypeResource
DescriptionResource schema for AWS::ImageBuilder::Component
Idawscc.imagebuilder.components

Fields

NameDatatypeDescription
arnstringThe Amazon Resource Name (ARN) of the component.
namestringThe name of the component.
versionstringThe version of the component.
descriptionstringThe description of the component.
change_descriptionstringThe change description of the component.
typestringThe type of the component denotes whether the component is used to build the image or only to test it.
platformstringThe platform of the component.
datastringThe data of the component.
kms_key_idstringThe KMS key identifier used to encrypt the component.
encryptedbooleanThe encryption status of the component.
tagsobjectThe tags associated with the component.
uristringThe uri of the component.
supported_os_versionsarrayThe operating system (OS) version supported by the component.
regionstringAWS region.

For more information, see AWS::ImageBuilder::Component.

Methods

NameResourceAccessible byRequired Params
create_resourcecomponentsINSERTName, Platform, Version, region
delete_resourcecomponentsDELETEIdentifier, region
update_resourcecomponentsUPDATEIdentifier, PatchDocument, region
list_resourcescomponents_list_onlySELECTregion
get_resourcecomponentsSELECTIdentifier, region

SELECT examples

Gets all properties from an individual component.

SELECT
region,
arn,
name,
version,
description,
change_description,
type,
platform,
data,
kms_key_id,
encrypted,
tags,
uri,
supported_os_versions
FROM awscc.imagebuilder.components
WHERE
region = 'us-east-1' AND
Identifier = '{{ arn }}';

INSERT example

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

/*+ create */
INSERT INTO awscc.imagebuilder.components (
Name,
Version,
Platform,
region
)
SELECT
'{{ name }}',
'{{ version }}',
'{{ platform }}',
'{{ region }}';

UPDATE example

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

/*+ update */
UPDATE awscc.imagebuilder.components
SET PatchDocument = string('{{ {
"Tags": tags
} | generate_patch_document }}')
WHERE
region = '{{ region }}' AND
Identifier = '{{ arn }}';

DELETE example

/*+ delete */
DELETE FROM awscc.imagebuilder.components
WHERE
Identifier = '{{ arn }}' AND
region = 'us-east-1';

Permissions

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

iam:CreateServiceLinkedRole,
iam:GetRole,
kms:GenerateDataKey,
kms:GenerateDataKeyPair,
kms:GenerateDataKeyPairWithoutPlaintext,
kms:GenerateDataKeyWithoutPlaintext,
kms:Encrypt,
kms:Decrypt,
s3:GetObject,
s3:HeadBucket,
s3:GetBucketLocation,
imagebuilder:TagResource,
imagebuilder:GetComponent,
imagebuilder:CreateComponent