interface InstanceLaunchTemplateProperty
| Language | Type name |
|---|---|
.NET | Amazon.CDK.AWS.ECS.CfnCapacityProvider.InstanceLaunchTemplateProperty |
Go | github.com/aws/aws-cdk-go/awscdk/v2/awsecs#CfnCapacityProvider_InstanceLaunchTemplateProperty |
Java | software.amazon.awscdk.services.ecs.CfnCapacityProvider.InstanceLaunchTemplateProperty |
Python | aws_cdk.aws_ecs.CfnCapacityProvider.InstanceLaunchTemplateProperty |
TypeScript | aws-cdk-lib » aws_ecs » CfnCapacityProvider » InstanceLaunchTemplateProperty |
The launch template configuration for Amazon ECS Managed Instances.
This defines how Amazon ECS launches Amazon EC2 instances, including the instance profile for your tasks, network and storage configuration, capacity options, and instance requirements for flexible instance type selection.
Example
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_ecs as ecs } from 'aws-cdk-lib';
const instanceLaunchTemplateProperty: ecs.CfnCapacityProvider.InstanceLaunchTemplateProperty = {
ec2InstanceProfileArn: 'ec2InstanceProfileArn',
networkConfiguration: {
subnets: ['subnets'],
// the properties below are optional
securityGroups: ['securityGroups'],
},
// the properties below are optional
instanceRequirements: {
memoryMiB: {
min: 123,
// the properties below are optional
max: 123,
},
vCpuCount: {
min: 123,
// the properties below are optional
max: 123,
},
// the properties below are optional
acceleratorCount: {
max: 123,
min: 123,
},
acceleratorManufacturers: ['acceleratorManufacturers'],
acceleratorNames: ['acceleratorNames'],
acceleratorTotalMemoryMiB: {
max: 123,
min: 123,
},
acceleratorTypes: ['acceleratorTypes'],
allowedInstanceTypes: ['allowedInstanceTypes'],
bareMetal: 'bareMetal',
baselineEbsBandwidthMbps: {
max: 123,
min: 123,
},
burstablePerformance: 'burstablePerformance',
cpuManufacturers: ['cpuManufacturers'],
excludedInstanceTypes: ['excludedInstanceTypes'],
instanceGenerations: ['instanceGenerations'],
localStorage: 'localStorage',
localStorageTypes: ['localStorageTypes'],
maxSpotPriceAsPercentageOfOptimalOnDemandPrice: 123,
memoryGiBPerVCpu: {
max: 123,
min: 123,
},
networkBandwidthGbps: {
max: 123,
min: 123,
},
networkInterfaceCount: {
max: 123,
min: 123,
},
onDemandMaxPricePercentageOverLowestPrice: 123,
requireHibernateSupport: false,
spotMaxPricePercentageOverLowestPrice: 123,
totalLocalStorageGb: {
max: 123,
min: 123,
},
},
monitoring: 'monitoring',
storageConfiguration: {
storageSizeGiB: 123,
},
};
Properties
| Name | Type | Description |
|---|---|---|
| ec2 | string | The Amazon Resource Name (ARN) of the instance profile that Amazon ECS applies to Amazon ECS Managed Instances. |
| network | IResolvable | Managed | The network configuration for Amazon ECS Managed Instances. |
| instance | IResolvable | Instance | The instance requirements. You can specify:. |
| monitoring? | string | CloudWatch provides two categories of monitoring: basic monitoring and detailed monitoring. |
| storage | IResolvable | Managed | The storage configuration for Amazon ECS Managed Instances. |
ec2InstanceProfileArn
Type:
string
The Amazon Resource Name (ARN) of the instance profile that Amazon ECS applies to Amazon ECS Managed Instances.
This instance profile must include the necessary permissions for your tasks to access AWS services and resources.
For more information, see Amazon ECS instance profile for Managed Instances in the Amazon ECS Developer Guide .
networkConfiguration
Type:
IResolvable | Managed
The network configuration for Amazon ECS Managed Instances.
This specifies the subnets and security groups that instances use for network connectivity.
instanceRequirements?
Type:
IResolvable | Instance
(optional)
The instance requirements. You can specify:.
- The instance types
- Instance requirements such as vCPU count, memory, network performance, and accelerator specifications
Amazon ECS automatically selects the instances that match the specified criteria.
monitoring?
Type:
string
(optional)
CloudWatch provides two categories of monitoring: basic monitoring and detailed monitoring.
By default, your managed instance is configured for basic monitoring. You can optionally enable detailed monitoring to help you more quickly identify and act on operational issues. You can enable or turn off detailed monitoring at launch or when the managed instance is running or stopped. For more information, see Detailed monitoring for Amazon ECS Managed Instances in the Amazon ECS Developer Guide.
storageConfiguration?
Type:
IResolvable | Managed
(optional)
The storage configuration for Amazon ECS Managed Instances.
This defines the root volume size and type for the instances.

.NET
Go
Java
Python
TypeScript