Class CfnInfrastructureConfiguration
- All Implemented Interfaces:
IInspectable,ITaggable,IInfrastructureConfigurationRef,software.amazon.jsii.JsiiSerializable,software.constructs.IConstruct,software.constructs.IDependable
An infrastructure configuration defines the environment in which your image will be built and tested.
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.*;
CfnInfrastructureConfiguration cfnInfrastructureConfiguration = CfnInfrastructureConfiguration.Builder.create(this, "MyCfnInfrastructureConfiguration")
.instanceProfileName("instanceProfileName")
.name("name")
// the properties below are optional
.description("description")
.instanceMetadataOptions(InstanceMetadataOptionsProperty.builder()
.httpPutResponseHopLimit(123)
.httpTokens("httpTokens")
.build())
.instanceTypes(List.of("instanceTypes"))
.keyPair("keyPair")
.logging(LoggingProperty.builder()
.s3Logs(S3LogsProperty.builder()
.s3BucketName("s3BucketName")
.s3KeyPrefix("s3KeyPrefix")
.build())
.build())
.placement(PlacementProperty.builder()
.availabilityZone("availabilityZone")
.hostId("hostId")
.hostResourceGroupArn("hostResourceGroupArn")
.tenancy("tenancy")
.build())
.resourceTags(Map.of(
"resourceTagsKey", "resourceTags"))
.securityGroupIds(List.of("securityGroupIds"))
.snsTopicArn("snsTopicArn")
.subnetId("subnetId")
.tags(Map.of(
"tagsKey", "tags"))
.terminateInstanceOnFailure(false)
.build();
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classA fluent builder forCfnInfrastructureConfiguration.static interfaceThe instance metadata options that apply to the HTTP requests that pipeline builds use to launch EC2 build and test instances.static interfaceLogging configuration defines where Image Builder uploads your logs.static interfaceBy default, EC2 instances run on shared tenancy hardware.static interfaceAmazon S3 logging configuration.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.services.imagebuilder.IInfrastructureConfigurationRef
IInfrastructureConfigurationRef.Jsii$Default, IInfrastructureConfigurationRef.Jsii$ProxyNested 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
ConstructorsModifierConstructorDescriptionprotectedCfnInfrastructureConfiguration(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protectedCfnInfrastructureConfiguration(software.amazon.jsii.JsiiObjectRef objRef) CfnInfrastructureConfiguration(software.constructs.Construct scope, String id, CfnInfrastructureConfigurationProps props) -
Method Summary
Modifier and TypeMethodDescriptionReturns the Amazon Resource Name (ARN) of the infrastructure configuration.The name of the infrastructure configuration.The description of the infrastructure configuration.A reference to a InfrastructureConfiguration resource.The instance metadata options that you can set for the HTTP requests that pipeline builds use to launch EC2 build and test instances.The instance profile to associate with the instance used to customize your Amazon EC2 AMI.The instance types of the infrastructure configuration.The key pair of the infrastructure configuration.The logging configuration of the infrastructure configuration.getName()The name of the infrastructure configuration.The instance placement settings that define where the instances that are launched from your image will run.The metadata tags to assign to the Amazon EC2 instance that Image Builder launches during the build process.The security group IDs to associate with the instance used to customize your Amazon EC2 AMI.The Amazon Resource Name (ARN) for the SNS topic to which we send image build event notifications.The subnet ID in which to place the instance used to customize your Amazon EC2 AMI.getTags()Tag Manager which manages the tags for this resource.The metadata tags to assign to the infrastructure configuration resource that Image Builder creates as output.The terminate instance on failure setting of the infrastructure configuration.voidinspect(TreeInspector inspector) Examines the CloudFormation resource and discloses attributes.renderProperties(Map<String, Object> props) voidsetDescription(String value) The description of the infrastructure configuration.voidThe instance metadata options that you can set for the HTTP requests that pipeline builds use to launch EC2 build and test instances.voidThe instance metadata options that you can set for the HTTP requests that pipeline builds use to launch EC2 build and test instances.voidsetInstanceProfileName(String value) The instance profile to associate with the instance used to customize your Amazon EC2 AMI.voidsetInstanceTypes(List<String> value) The instance types of the infrastructure configuration.voidsetKeyPair(String value) The key pair of the infrastructure configuration.voidsetLogging(IResolvable value) The logging configuration of the infrastructure configuration.voidThe logging configuration of the infrastructure configuration.voidThe name of the infrastructure configuration.voidsetPlacement(IResolvable value) The instance placement settings that define where the instances that are launched from your image will run.voidThe instance placement settings that define where the instances that are launched from your image will run.voidsetResourceTags(Map<String, String> value) The metadata tags to assign to the Amazon EC2 instance that Image Builder launches during the build process.voidsetResourceTags(IResolvable value) The metadata tags to assign to the Amazon EC2 instance that Image Builder launches during the build process.voidsetSecurityGroupIds(List<String> value) The security group IDs to associate with the instance used to customize your Amazon EC2 AMI.voidsetSnsTopicArn(String value) The Amazon Resource Name (ARN) for the SNS topic to which we send image build event notifications.voidsetSubnetId(String value) The subnet ID in which to place the instance used to customize your Amazon EC2 AMI.voidsetTagsRaw(Map<String, String> value) The metadata tags to assign to the infrastructure configuration resource that Image Builder creates as output.voidThe terminate instance on failure setting of the infrastructure configuration.voidThe terminate instance on failure setting of the infrastructure configuration.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.constructs.IConstruct
getNodeMethods 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
-
CfnInfrastructureConfiguration
protected CfnInfrastructureConfiguration(software.amazon.jsii.JsiiObjectRef objRef) -
CfnInfrastructureConfiguration
protected CfnInfrastructureConfiguration(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
CfnInfrastructureConfiguration
@Stability(Stable) public CfnInfrastructureConfiguration(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull CfnInfrastructureConfigurationProps 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 infrastructure configuration.The following pattern is applied:
^arn:aws[^:]*:imagebuilder:[^:]+:(?:\d{12}|aws):(?:image-recipe|infrastructure-configuration|distribution-configuration|component|image|image-pipeline)/[a-z0-9-_]+(?:/(?:(?:x|\d+)\.(?:x|\d+)\.(?:x|\d+))(?:/\d+)?)?$. -
getAttrName
The name of the infrastructure configuration. -
getCfnProperties
- Overrides:
getCfnPropertiesin classCfnResource
-
getInfrastructureConfigurationRef
@Stability(Stable) @NotNull public InfrastructureConfigurationReference getInfrastructureConfigurationRef()A reference to a InfrastructureConfiguration resource.- Specified by:
getInfrastructureConfigurationRefin interfaceIInfrastructureConfigurationRef
-
getTags
Tag Manager which manages the tags for this resource. -
getInstanceProfileName
The instance profile to associate with the instance used to customize your Amazon EC2 AMI. -
setInstanceProfileName
The instance profile to associate with the instance used to customize your Amazon EC2 AMI. -
getName
The name of the infrastructure configuration. -
setName
The name of the infrastructure configuration. -
getDescription
The description of the infrastructure configuration. -
setDescription
The description of the infrastructure configuration. -
getInstanceMetadataOptions
The instance metadata options that you can set for the HTTP requests that pipeline builds use to launch EC2 build and test instances.Returns union: either
IResolvableorCfnInfrastructureConfiguration.InstanceMetadataOptionsProperty -
setInstanceMetadataOptions
The instance metadata options that you can set for the HTTP requests that pipeline builds use to launch EC2 build and test instances. -
setInstanceMetadataOptions
@Stability(Stable) public void setInstanceMetadataOptions(@Nullable CfnInfrastructureConfiguration.InstanceMetadataOptionsProperty value) The instance metadata options that you can set for the HTTP requests that pipeline builds use to launch EC2 build and test instances. -
getInstanceTypes
The instance types of the infrastructure configuration. -
setInstanceTypes
The instance types of the infrastructure configuration. -
getKeyPair
The key pair of the infrastructure configuration. -
setKeyPair
The key pair of the infrastructure configuration. -
getLogging
The logging configuration of the infrastructure configuration.Returns union: either
IResolvableorCfnInfrastructureConfiguration.LoggingProperty -
setLogging
The logging configuration of the infrastructure configuration. -
setLogging
@Stability(Stable) public void setLogging(@Nullable CfnInfrastructureConfiguration.LoggingProperty value) The logging configuration of the infrastructure configuration. -
getPlacement
The instance placement settings that define where the instances that are launched from your image will run.Returns union: either
IResolvableorCfnInfrastructureConfiguration.PlacementProperty -
setPlacement
The instance placement settings that define where the instances that are launched from your image will run. -
setPlacement
@Stability(Stable) public void setPlacement(@Nullable CfnInfrastructureConfiguration.PlacementProperty value) The instance placement settings that define where the instances that are launched from your image will run. -
getResourceTags
The metadata tags to assign to the Amazon EC2 instance that Image Builder launches during the build process.Returns union: either Mapinvalid input: '<'String,
String> orIResolvable -
setResourceTags
The metadata tags to assign to the Amazon EC2 instance that Image Builder launches during the build process. -
setResourceTags
The metadata tags to assign to the Amazon EC2 instance that Image Builder launches during the build process. -
getSecurityGroupIds
The security group IDs to associate with the instance used to customize your Amazon EC2 AMI. -
setSecurityGroupIds
The security group IDs to associate with the instance used to customize your Amazon EC2 AMI. -
getSnsTopicArn
The Amazon Resource Name (ARN) for the SNS topic to which we send image build event notifications. -
setSnsTopicArn
The Amazon Resource Name (ARN) for the SNS topic to which we send image build event notifications. -
getSubnetId
The subnet ID in which to place the instance used to customize your Amazon EC2 AMI. -
setSubnetId
The subnet ID in which to place the instance used to customize your Amazon EC2 AMI. -
getTagsRaw
The metadata tags to assign to the infrastructure configuration resource that Image Builder creates as output. -
setTagsRaw
The metadata tags to assign to the infrastructure configuration resource that Image Builder creates as output. -
getTerminateInstanceOnFailure
The terminate instance on failure setting of the infrastructure configuration.Returns union: either
BooleanorIResolvable -
setTerminateInstanceOnFailure
The terminate instance on failure setting of the infrastructure configuration. -
setTerminateInstanceOnFailure
The terminate instance on failure setting of the infrastructure configuration.
-