interface CapacityReservationSpecificationProperty
Language | Type name |
---|---|
.NET | Amazon.CDK.AWS.EC2.CfnLaunchTemplate.CapacityReservationSpecificationProperty |
Go | github.com/aws/aws-cdk-go/awscdk/v2/awsec2#CfnLaunchTemplate_CapacityReservationSpecificationProperty |
Java | software.amazon.awscdk.services.ec2.CfnLaunchTemplate.CapacityReservationSpecificationProperty |
Python | aws_cdk.aws_ec2.CfnLaunchTemplate.CapacityReservationSpecificationProperty |
TypeScript | aws-cdk-lib » aws_ec2 » CfnLaunchTemplate » CapacityReservationSpecificationProperty |
Specifies an instance's Capacity Reservation targeting option. You can specify only one option at a time.
CapacityReservationSpecification
is a property of AWS::EC2::LaunchTemplate LaunchTemplateData .
Example
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_ec2 as ec2 } from 'aws-cdk-lib';
const capacityReservationSpecificationProperty: ec2.CfnLaunchTemplate.CapacityReservationSpecificationProperty = {
capacityReservationPreference: 'capacityReservationPreference',
capacityReservationTarget: {
capacityReservationId: 'capacityReservationId',
capacityReservationResourceGroupArn: 'capacityReservationResourceGroupArn',
},
};
Properties
Name | Type | Description |
---|---|---|
capacity | string | Indicates the instance's Capacity Reservation preferences. Possible preferences include:. |
capacity | IResolvable | Capacity | Information about the target Capacity Reservation or Capacity Reservation group. |
capacityReservationPreference?
Type:
string
(optional)
Indicates the instance's Capacity Reservation preferences. Possible preferences include:.
open
- The instance can run in anyopen
Capacity Reservation that has matching attributes (instance type, platform, Availability Zone).none
- The instance avoids running in a Capacity Reservation even if one is available. The instance runs in On-Demand capacity.
capacityReservationTarget?
Type:
IResolvable
|
Capacity
(optional)
Information about the target Capacity Reservation or Capacity Reservation group.