AWS Fundamentals Logo
AWS Fundamentals
L1 ConstructAWS::ImageBuilder::ContainerRecipe

CfnContainerRecipe

Creates a new container recipe. Container recipes define how images are configured, tested, and assessed.

Import

import { CfnContainerRecipe } from 'aws-cdk-lib/aws-imagebuilder';

Or use the module namespace:

import * as imagebuilder from 'aws-cdk-lib/aws-imagebuilder';
// imagebuilder.CfnContainerRecipe

Properties

Configuration passed to the constructor as CfnContainerRecipeProps.

containerTypeRequired
string

Specifies the type of container, such as Docker.

nameRequired
string

The name of the container recipe.

parentImageRequired
string

The base image for customizations specified in the container recipe. This can contain an Image Builder image resource ARN or a container image URI, for example `amazonlinux:latest` .

targetRepositoryRequired
IResolvable | TargetContainerRepositoryProperty

The destination repository for the container image.

versionRequired
string

The semantic version of the container recipe. This version follows the semantic version syntax. > The semantic version has four nodes: <major>.<minor>.<patch>/<build>. You can assign values for the first three, and can filter on all of them. > > *Assignment:* For the first three nodes you can assign any positive integer value, including zero, with an upper limit of 2^30-1, or 1073741823 for each node. Image Builder automatically assigns the build number to the fourth node. > > *Patterns:* You can use any numeric pattern that adheres to the assignment requirements for the nodes that you can assign. For example, you might choose a software version pattern, such as 1.0.0, or a date, such as 2021.01.01.

componentsOptional
IResolvable | IResolvable | ComponentConfigurationProperty[]

Build and test components that are included in the container recipe. Recipes require a minimum of one build component, and can have a maximum of 20 build and test components in any combination.

descriptionOptional
string

The description of the container recipe.

dockerfileTemplateDataOptional
string

Dockerfiles are text documents that are used to build Docker containers, and ensure that they contain all of the elements required by the application running inside. The template data consists of contextual variables where Image Builder places build information or scripts, based on your container image recipe.

dockerfileTemplateUriOptional
string

The S3 URI for the Dockerfile that will be used to build your container image.

imageOsVersionOverrideOptional
string

Specifies the operating system version for the base image.

instanceConfigurationOptional
IResolvable | InstanceConfigurationProperty

A group of options that can be used to configure an instance for building and testing container images.

kmsKeyIdOptional
string

The Amazon Resource Name (ARN) that uniquely identifies which KMS key is used to encrypt the container image for distribution to the target Region. This can be either the Key ARN or the Alias ARN. For more information, see [Key identifiers (KeyId)](https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#key-id-key-ARN) in the *AWS Key Management Service Developer Guide* .

platformOverrideOptional
string

Specifies the operating system platform when you use a custom base image.

tagsOptional
{ [key: string]: string }

Tags that are attached to the container recipe.

workingDirectoryOptional
string

The working directory for use during build and test workflows.

CloudFormation Resource

This L1 construct maps directly to the following CloudFormation resource type.

Learn AWS the Practical Way

Our bi-weekly newsletter teaches hands-on AWS fundamentals. No certification fluff - just practical knowledge.

Subscribe to Newsletter