Interface ImageRecipe.Builder
- All Superinterfaces:
Buildable,CopyableBuilder<ImageRecipe.Builder,,ImageRecipe> SdkBuilder<ImageRecipe.Builder,,ImageRecipe> SdkPojo
- Enclosing class:
ImageRecipe
-
Method Summary
Modifier and TypeMethodDescriptiondefault ImageRecipe.BuilderadditionalInstanceConfiguration(Consumer<AdditionalInstanceConfiguration.Builder> additionalInstanceConfiguration) Before you create a new AMI, Image Builder launches temporary Amazon EC2 instances to build and test your image configuration.additionalInstanceConfiguration(AdditionalInstanceConfiguration additionalInstanceConfiguration) Before you create a new AMI, Image Builder launches temporary Amazon EC2 instances to build and test your image configuration.Tags that are applied to the AMI that Image Builder creates during the Build phase prior to image distribution.amiWatermarks(String... amiWatermarks) The AMI watermark names attached to the output AMI from this recipe.amiWatermarks(Collection<String> amiWatermarks) The AMI watermark names attached to the output AMI from this recipe.The Amazon Resource Name (ARN) of the image recipe.blockDeviceMappings(Collection<InstanceBlockDeviceMapping> blockDeviceMappings) The block device mappings to apply when creating images from this recipe.blockDeviceMappings(Consumer<InstanceBlockDeviceMapping.Builder>... blockDeviceMappings) The block device mappings to apply when creating images from this recipe.blockDeviceMappings(InstanceBlockDeviceMapping... blockDeviceMappings) The block device mappings to apply when creating images from this recipe.components(Collection<ComponentConfiguration> components) The components that are included in the image recipe.components(Consumer<ComponentConfiguration.Builder>... components) The components that are included in the image recipe.components(ComponentConfiguration... components) The components that are included in the image recipe.dateCreated(String dateCreated) The date on which this image recipe was created.description(String description) The description of the image recipe.The name of the image recipe.The owner of the image recipe.parentImage(String parentImage) The base image for customizations specified in the image recipe.The platform of the image recipe.The platform of the image recipe.The tags of the image recipe.The output image type.The output image type.The version of the image recipe.workingDirectory(String workingDirectory) The working directory used during build and test workflows.Methods inherited from interface software.amazon.awssdk.utils.builder.CopyableBuilder
copyMethods inherited from interface software.amazon.awssdk.utils.builder.SdkBuilder
applyMutation, buildMethods inherited from interface software.amazon.awssdk.core.SdkPojo
equalsBySdkFields, sdkFieldNameToField, sdkFields
-
Method Details
-
arn
The Amazon Resource Name (ARN) of the image recipe.
- Parameters:
arn- The Amazon Resource Name (ARN) of the image recipe.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
type
The output image type. For an image recipe, this is always AMI. Container images are built from container recipes, a separate resource. This field isn't currently returned in responses.
- Parameters:
type- The output image type. For an image recipe, this is always AMI. Container images are built from container recipes, a separate resource. This field isn't currently returned in responses.- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
-
type
The output image type. For an image recipe, this is always AMI. Container images are built from container recipes, a separate resource. This field isn't currently returned in responses.
- Parameters:
type- The output image type. For an image recipe, this is always AMI. Container images are built from container recipes, a separate resource. This field isn't currently returned in responses.- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
-
name
The name of the image recipe.
- Parameters:
name- The name of the image recipe.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
description
The description of the image recipe.
- Parameters:
description- The description of the image recipe.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
platform
The platform of the image recipe.
- Parameters:
platform- The platform of the image recipe.- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
-
platform
The platform of the image recipe.
- Parameters:
platform- The platform of the image recipe.- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
-
owner
The owner of the image recipe.
- Parameters:
owner- The owner of the image recipe.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
version
The version of the image recipe.
- Parameters:
version- The version of the image recipe.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
components
The components that are included in the image recipe. A recipe can contain a maximum of 20 build and test components in any combination, by default. This maximum is an adjustable quota. For more information, see EC2 Image Builder endpoints and quotas in the Amazon Web Services General Reference.
- Parameters:
components- The components that are included in the image recipe. A recipe can contain a maximum of 20 build and test components in any combination, by default. This maximum is an adjustable quota. For more information, see EC2 Image Builder endpoints and quotas in the Amazon Web Services General Reference.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
components
The components that are included in the image recipe. A recipe can contain a maximum of 20 build and test components in any combination, by default. This maximum is an adjustable quota. For more information, see EC2 Image Builder endpoints and quotas in the Amazon Web Services General Reference.
- Parameters:
components- The components that are included in the image recipe. A recipe can contain a maximum of 20 build and test components in any combination, by default. This maximum is an adjustable quota. For more information, see EC2 Image Builder endpoints and quotas in the Amazon Web Services General Reference.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
components
The components that are included in the image recipe. A recipe can contain a maximum of 20 build and test components in any combination, by default. This maximum is an adjustable quota. For more information, see EC2 Image Builder endpoints and quotas in the Amazon Web Services General Reference.
This is a convenience method that creates an instance of theComponentConfiguration.Builderavoiding the need to create one manually viaComponentConfiguration.builder().When the
Consumercompletes,SdkBuilder.build()is called immediately and its result is passed tocomponents(List<ComponentConfiguration>).- Parameters:
components- a consumer that will call methods onComponentConfiguration.Builder- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
-
parentImage
The base image for customizations specified in the image recipe. You can specify the parent image using one of the following options:
-
AMI ID
-
Image Builder image Amazon Resource Name (ARN)
-
Amazon Web Services Systems Manager (SSM) Parameter Store Parameter, prefixed by
ssm:, followed by the parameter name or ARN. -
Amazon Web Services Marketplace product ID
- Parameters:
parentImage- The base image for customizations specified in the image recipe. You can specify the parent image using one of the following options:-
AMI ID
-
Image Builder image Amazon Resource Name (ARN)
-
Amazon Web Services Systems Manager (SSM) Parameter Store Parameter, prefixed by
ssm:, followed by the parameter name or ARN. -
Amazon Web Services Marketplace product ID
-
- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
-
blockDeviceMappings
The block device mappings to apply when creating images from this recipe.
- Parameters:
blockDeviceMappings- The block device mappings to apply when creating images from this recipe.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
blockDeviceMappings
The block device mappings to apply when creating images from this recipe.
- Parameters:
blockDeviceMappings- The block device mappings to apply when creating images from this recipe.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
blockDeviceMappings
ImageRecipe.Builder blockDeviceMappings(Consumer<InstanceBlockDeviceMapping.Builder>... blockDeviceMappings) The block device mappings to apply when creating images from this recipe.
This is a convenience method that creates an instance of theInstanceBlockDeviceMapping.Builderavoiding the need to create one manually viaInstanceBlockDeviceMapping.builder().When the
Consumercompletes,SdkBuilder.build()is called immediately and its result is passed toblockDeviceMappings(List<InstanceBlockDeviceMapping>).- Parameters:
blockDeviceMappings- a consumer that will call methods onInstanceBlockDeviceMapping.Builder- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
-
dateCreated
The date on which this image recipe was created.
- Parameters:
dateCreated- The date on which this image recipe was created.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
tags
The tags of the image recipe.
- Parameters:
tags- The tags of the image recipe.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
workingDirectory
The working directory used during build and test workflows. If you don't specify a working directory, Image Builder uses
/tmpfor Linux and macOS build instances, andC:/for Windows build instances.- Parameters:
workingDirectory- The working directory used during build and test workflows. If you don't specify a working directory, Image Builder uses/tmpfor Linux and macOS build instances, andC:/for Windows build instances.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
additionalInstanceConfiguration
ImageRecipe.Builder additionalInstanceConfiguration(AdditionalInstanceConfiguration additionalInstanceConfiguration) Before you create a new AMI, Image Builder launches temporary Amazon EC2 instances to build and test your image configuration. Instance configuration adds a layer of control over those instances. You can define settings and add scripts to run when Image Builder launches your build instance.
- Parameters:
additionalInstanceConfiguration- Before you create a new AMI, Image Builder launches temporary Amazon EC2 instances to build and test your image configuration. Instance configuration adds a layer of control over those instances. You can define settings and add scripts to run when Image Builder launches your build instance.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
additionalInstanceConfiguration
default ImageRecipe.Builder additionalInstanceConfiguration(Consumer<AdditionalInstanceConfiguration.Builder> additionalInstanceConfiguration) Before you create a new AMI, Image Builder launches temporary Amazon EC2 instances to build and test your image configuration. Instance configuration adds a layer of control over those instances. You can define settings and add scripts to run when Image Builder launches your build instance.
This is a convenience method that creates an instance of theAdditionalInstanceConfiguration.Builderavoiding the need to create one manually viaAdditionalInstanceConfiguration.builder().When the
Consumercompletes,SdkBuilder.build()is called immediately and its result is passed toadditionalInstanceConfiguration(AdditionalInstanceConfiguration).- Parameters:
additionalInstanceConfiguration- a consumer that will call methods onAdditionalInstanceConfiguration.Builder- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
-
amiTags
Tags that are applied to the AMI that Image Builder creates during the Build phase prior to image distribution.
- Parameters:
amiTags- Tags that are applied to the AMI that Image Builder creates during the Build phase prior to image distribution.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
amiWatermarks
The AMI watermark names attached to the output AMI from this recipe. AMI watermarks are lineage markers that automatically propagate to derivative AMIs when the source AMI is copied or distributed.
- Parameters:
amiWatermarks- The AMI watermark names attached to the output AMI from this recipe. AMI watermarks are lineage markers that automatically propagate to derivative AMIs when the source AMI is copied or distributed.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
amiWatermarks
The AMI watermark names attached to the output AMI from this recipe. AMI watermarks are lineage markers that automatically propagate to derivative AMIs when the source AMI is copied or distributed.
- Parameters:
amiWatermarks- The AMI watermark names attached to the output AMI from this recipe. AMI watermarks are lineage markers that automatically propagate to derivative AMIs when the source AMI is copied or distributed.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-