interface HibernationOptionsProperty
| Language | Type name |
|---|---|
.NET | Amazon.CDK.AWS.EC2.CfnInstance.HibernationOptionsProperty |
Go | github.com/aws/aws-cdk-go/awscdk/v2/awsec2#CfnInstance_HibernationOptionsProperty |
Java | software.amazon.awscdk.services.ec2.CfnInstance.HibernationOptionsProperty |
Python | aws_cdk.aws_ec2.CfnInstance.HibernationOptionsProperty |
TypeScript | aws-cdk-lib » aws_ec2 » CfnInstance » HibernationOptionsProperty |
Specifies the hibernation options for the instance.
HibernationOptions is a property of the AWS::EC2::Instance resource.
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 hibernationOptionsProperty: ec2.CfnInstance.HibernationOptionsProperty = {
configured: false,
};
Properties
| Name | Type | Description |
|---|---|---|
| configured? | boolean | IResolvable | Set to true to enable your instance for hibernation. |
configured?
Type:
boolean | IResolvable
(optional, default: false)
Set to true to enable your instance for hibernation.
For Spot Instances, if you set Configured to true , either omit the InstanceInterruptionBehavior parameter (for SpotMarketOptions ), or set it to hibernate . When Configured is true:
- If you omit
InstanceInterruptionBehavior, it defaults tohibernate. - If you set
InstanceInterruptionBehaviorto a value other thanhibernate, you'll get an error.
Default: false

.NET
Go
Java
Python
TypeScript