Class CfnImageRecipe
java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
software.amazon.awscdk.CfnElement
software.amazon.awscdk.CfnRefElement
software.amazon.awscdk.CfnResource
software.amazon.awscdk.services.imagebuilder.CfnImageRecipe
- All Implemented Interfaces:
IInspectable,ITaggable,software.amazon.jsii.JsiiSerializable,software.constructs.IConstruct,software.constructs.IDependable
@Generated(value="jsii-pacmak/1.104.0 (build e79254c)",
date="2024-11-06T23:25:11.122Z")
@Stability(Stable)
public class CfnImageRecipe
extends CfnResource
implements IInspectable, ITaggable
An Image Builder image recipe is a document that defines the base image and the components to be applied to the base image to produce the desired configuration for the output image.
You can use an image recipe to duplicate builds. Image Builder image recipes can be shared, branched, and edited using the console wizard, the AWS CLI , or the API. You can use image recipes with your version control software to maintain shareable versioned image recipes.
Example:
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.imagebuilder.*;
CfnImageRecipe cfnImageRecipe = CfnImageRecipe.Builder.create(this, "MyCfnImageRecipe")
.components(List.of(ComponentConfigurationProperty.builder()
.componentArn("componentArn")
.parameters(List.of(ComponentParameterProperty.builder()
.name("name")
.value(List.of("value"))
.build()))
.build()))
.name("name")
.parentImage("parentImage")
.version("version")
// the properties below are optional
.additionalInstanceConfiguration(AdditionalInstanceConfigurationProperty.builder()
.systemsManagerAgent(SystemsManagerAgentProperty.builder()
.uninstallAfterBuild(false)
.build())
.userDataOverride("userDataOverride")
.build())
.blockDeviceMappings(List.of(InstanceBlockDeviceMappingProperty.builder()
.deviceName("deviceName")
.ebs(EbsInstanceBlockDeviceSpecificationProperty.builder()
.deleteOnTermination(false)
.encrypted(false)
.iops(123)
.kmsKeyId("kmsKeyId")
.snapshotId("snapshotId")
.throughput(123)
.volumeSize(123)
.volumeType("volumeType")
.build())
.noDevice("noDevice")
.virtualName("virtualName")
.build()))
.description("description")
.tags(Map.of(
"tagsKey", "tags"))
.workingDirectory("workingDirectory")
.build();
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic interfaceIn addition to your infrastructure configuration, these settings provide an extra layer of control over your build instances.static final classA fluent builder forCfnImageRecipe.static interfaceConfiguration details of the component.static interfaceContains a key/value pair that sets the named component parameter.static interfaceThe image recipe EBS instance block device specification includes the Amazon EBS-specific block device mapping specifications for the image.static interfaceDefines block device mappings for the instance used to configure your image.static interfaceContains settings for the Systems Manager agent on your build instance.Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationModeNested classes/interfaces inherited from interface software.constructs.IConstruct
software.constructs.IConstruct.Jsii$DefaultNested classes/interfaces inherited from interface software.amazon.awscdk.IInspectable
IInspectable.Jsii$Default, IInspectable.Jsii$ProxyNested classes/interfaces inherited from interface software.amazon.awscdk.ITaggable
ITaggable.Jsii$Default, ITaggable.Jsii$Proxy -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringThe CloudFormation resource type name for this resource class. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedCfnImageRecipe(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protectedCfnImageRecipe(software.amazon.jsii.JsiiObjectRef objRef) CfnImageRecipe(software.constructs.Construct scope, String id, CfnImageRecipeProps props) -
Method Summary
Modifier and TypeMethodDescriptionBefore you create a new AMI, Image Builder launches temporary Amazon EC2 instances to build and test your image configuration.Returns the Amazon Resource Name (ARN) of the image recipe.The name of the image recipe.The block device mappings to apply when creating images from this recipe.The components of the image recipe.The description of the image recipe.getName()The name of the image recipe.The parent image of the image recipe.getTags()Tag Manager which manages the tags for this resource.The tags of the image recipe.The semantic version of the image recipe.The working directory to be used during build and test workflows.voidinspect(TreeInspector inspector) Examines the CloudFormation resource and discloses attributes.renderProperties(Map<String, Object> props) voidBefore you create a new AMI, Image Builder launches temporary Amazon EC2 instances to build and test your image configuration.voidBefore you create a new AMI, Image Builder launches temporary Amazon EC2 instances to build and test your image configuration.voidsetBlockDeviceMappings(List<Object> value) The block device mappings to apply when creating images from this recipe.voidThe block device mappings to apply when creating images from this recipe.voidsetComponents(List<Object> value) The components of the image recipe.voidsetComponents(IResolvable value) The components of the image recipe.voidsetDescription(String value) The description of the image recipe.voidThe name of the image recipe.voidsetParentImage(String value) The parent image of the image recipe.voidsetTagsRaw(Map<String, String> value) The tags of the image recipe.voidsetVersion(String value) The semantic version of the image recipe.voidsetWorkingDirectory(String value) The working directory to be used during build and test workflows.Methods inherited from class software.amazon.awscdk.CfnResource
addDeletionOverride, addDependency, addDependsOn, addMetadata, addOverride, addPropertyDeletionOverride, addPropertyOverride, applyRemovalPolicy, applyRemovalPolicy, applyRemovalPolicy, getAtt, getAtt, getCfnOptions, getCfnResourceType, getMetadata, getUpdatedProperites, getUpdatedProperties, isCfnResource, obtainDependencies, obtainResourceDependencies, removeDependency, replaceDependency, shouldSynthesize, toString, validatePropertiesMethods inherited from class software.amazon.awscdk.CfnRefElement
getRefMethods inherited from class software.amazon.awscdk.CfnElement
getCreationStack, getLogicalId, getStack, isCfnElement, overrideLogicalIdMethods inherited from class software.constructs.Construct
getNode, isConstructMethods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSetMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Field Details
-
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
-
-
Constructor Details
-
CfnImageRecipe
protected CfnImageRecipe(software.amazon.jsii.JsiiObjectRef objRef) -
CfnImageRecipe
protected CfnImageRecipe(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
CfnImageRecipe
@Stability(Stable) public CfnImageRecipe(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull CfnImageRecipeProps props) - Parameters:
scope- Scope in which this resource is defined. This parameter is required.id- Construct identifier for this resource (unique in its scope). This parameter is required.props- Resource properties. This parameter is required.
-
-
Method Details
-
inspect
Examines the CloudFormation resource and discloses attributes.- Specified by:
inspectin interfaceIInspectable- Parameters:
inspector- tree inspector to collect and process attributes. This parameter is required.
-
renderProperties
@Stability(Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String, Object> props) - Overrides:
renderPropertiesin classCfnResource- Parameters:
props- This parameter is required.
-
getAttrArn
Returns the Amazon Resource Name (ARN) of the image recipe.For example,
arn:aws:imagebuilder:us-east-1:123456789012:image-recipe/mybasicrecipe/2019.12.03. -
getAttrName
The name of the image recipe. -
getCfnProperties
- Overrides:
getCfnPropertiesin classCfnResource
-
getTags
Tag Manager which manages the tags for this resource. -
getComponents
The components of the image recipe. -
setComponents
The components of the image recipe. -
setComponents
The components of the image recipe. -
getName
The name of the image recipe. -
setName
The name of the image recipe. -
getParentImage
The parent image of the image recipe. -
setParentImage
The parent image of the image recipe. -
getVersion
The semantic version of the image recipe. -
setVersion
The semantic version of the image recipe. -
getAdditionalInstanceConfiguration
Before you create a new AMI, Image Builder launches temporary Amazon EC2 instances to build and test your image configuration. -
setAdditionalInstanceConfiguration
Before you create a new AMI, Image Builder launches temporary Amazon EC2 instances to build and test your image configuration. -
setAdditionalInstanceConfiguration
@Stability(Stable) public void setAdditionalInstanceConfiguration(@Nullable CfnImageRecipe.AdditionalInstanceConfigurationProperty value) Before you create a new AMI, Image Builder launches temporary Amazon EC2 instances to build and test your image configuration. -
getBlockDeviceMappings
The block device mappings to apply when creating images from this recipe. -
setBlockDeviceMappings
The block device mappings to apply when creating images from this recipe. -
setBlockDeviceMappings
The block device mappings to apply when creating images from this recipe. -
getDescription
The description of the image recipe. -
setDescription
The description of the image recipe. -
getTagsRaw
The tags of the image recipe. -
setTagsRaw
The tags of the image recipe. -
getWorkingDirectory
The working directory to be used during build and test workflows. -
setWorkingDirectory
The working directory to be used during build and test workflows.
-