Skip to main content

image_recipes

Creates, updates, deletes or gets an image_recipe resource or lists image_recipes in a region

Overview

Nameimage_recipes
TypeResource
DescriptionResource schema for AWS::ImageBuilder::ImageRecipe
Idaws.imagebuilder.image_recipes

Fields

NameDatatypeDescription
arnstringThe Amazon Resource Name (ARN) of the image recipe.
namestringThe name of the image recipe.
descriptionstringThe description of the image recipe.
versionstringThe version of the image recipe.
componentsarrayThe components of the image recipe.
block_device_mappingsarrayThe block device mappings to apply when creating images from this recipe.
parent_imagestringThe parent image of the image recipe.
working_directorystringThe working directory to be used during build and test workflows.
additional_instance_configurationobjectSpecify additional settings and launch scripts for your build instances.
tagsobjectThe tags of the image recipe.
regionstringAWS region.

Methods

NameAccessible byRequired Params
create_resourceINSERTName, Version, Components, ParentImage, region
delete_resourceDELETEdata__Identifier, region
list_resourcesSELECTregion
get_resourceSELECTdata__Identifier, region

SELECT examples

Gets all image_recipes in a region.

SELECT
region,
arn,
name,
description,
version,
components,
block_device_mappings,
parent_image,
working_directory,
additional_instance_configuration,
tags
FROM aws.imagebuilder.image_recipes
WHERE region = 'us-east-1';

Gets all properties from an individual image_recipe.

SELECT
region,
arn,
name,
description,
version,
components,
block_device_mappings,
parent_image,
working_directory,
additional_instance_configuration,
tags
FROM aws.imagebuilder.image_recipes
WHERE region = 'us-east-1' AND data__Identifier = '<Arn>';

INSERT example

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

/*+ create */
INSERT INTO aws.imagebuilder.image_recipes (
Name,
Version,
Components,
ParentImage,
region
)
SELECT
'{{ Name }}',
'{{ Version }}',
'{{ Components }}',
'{{ ParentImage }}',
'{{ region }}';

DELETE example

/*+ delete */
DELETE FROM aws.imagebuilder.image_recipes
WHERE data__Identifier = '<Arn>'
AND region = 'us-east-1';

Permissions

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

Create

iam:GetRole,
iam:CreateServiceLinkedRole,
imagebuilder:GetComponent,
imagebuilder:GetImage,
imagebuilder:TagResource,
imagebuilder:GetImageRecipe,
imagebuilder:CreateImageRecipe,
ec2:DescribeImages

Read

imagebuilder:GetImageRecipe

Delete

imagebuilder:UnTagResource,
imagebuilder:GetImageRecipe,
imagebuilder:DeleteImageRecipe

List

imagebuilder:ListImageRecipes