Experimental
@aws-cdk/aws-imagebuilder-alpha is an experimental (alpha) package: its API may change in any release, without a major version bump.
ContainerRecipeProps Struct
Properties for creating a Container Recipe resource.
Example
const containerRecipe = new imagebuilder.ContainerRecipe(this, 'MyContainerRecipe', {
baseImage: imagebuilder.BaseContainerImage.fromDockerHub('amazonlinux', 'latest'),
targetRepository: imagebuilder.Repository.fromEcr(
ecr.Repository.fromRepositoryName(this, 'Repository', 'my-container-repo')
)
});
const containerPipeline = new imagebuilder.ImagePipeline(this, 'MyContainerPipeline', {
recipe: exampleContainerRecipe
});
Properties
baseImageBaseContainerImagebase_imageBaseContainerImagebaseImageBaseContainerImageBaseImageBaseContainerImageBaseImageBaseContainerImagerequired#componentsComponentConfiguration[]componentstyping.List[ComponentConfiguration]componentsList<ComponentConfiguration>ComponentsComponentConfiguration[]Components*[]ComponentConfiguration= None#containerRecipeNamestringcontainer_recipe_namestrcontainerRecipeNameStringContainerRecipeNamestringContainerRecipeName*string#Default: a name is generated
containerRecipeVersionstringcontainer_recipe_versionstrcontainerRecipeVersionStringContainerRecipeVersionstringContainerRecipeVersion*string= 1.0.x#dockerfileDockerfileDatadockerfileDockerfileDatadockerfileDockerfileDataDockerfileDockerfileDataDockerfileDockerfileData#Default: a standard dockerfile template will be generated to pull the base image, perform environment setup, and run all components in the recipe
instanceBlockDevicesBlockDevice[]instance_block_devicestyping.List[BlockDevice]instanceBlockDevicesList<BlockDevice>InstanceBlockDevicesBlockDevice[]InstanceBlockDevices*[]BlockDevice#Default: the block devices of the instance image will be used
instanceImageContainerInstanceImageinstance_imageContainerInstanceImageinstanceImageContainerInstanceImageInstanceImageContainerInstanceImageInstanceImageContainerInstanceImage#Default: Image Builder will use the appropriate ECS-optimized AMI
Default: Image Builder will determine the OS version of the base image, if sourced from a third-party container registry. Otherwise, the OS version of the base image is required.
tags{ [key: string]: string }tagstyping.Mapping[str, str]tagsMap<String, String>TagsIDictionary<string, string>Tags*map[string]*string= None#targetRepositoryRepositorytarget_repositoryRepositorytargetRepositoryRepositoryTargetRepositoryRepositoryTargetRepositoryRepositoryrequired#workingDirectorystringworking_directorystrworkingDirectoryStringWorkingDirectorystringWorkingDirectory*string#Default: the Image Builder default working directory is used. For Linux and macOS builds, this would be /tmp. For Windows builds, this would be C:/