AWS Fundamentals Logo
AWS Fundamentals
L1 ConstructAWS::Lightsail::Disk

CfnDisk

The `AWS::Lightsail::Disk` resource specifies a disk that can be attached to an Amazon Lightsail instance that is in the same AWS Region and Availability Zone.

Import

import { CfnDisk } from 'aws-cdk-lib/aws-lightsail';

Or use the module namespace:

import * as lightsail from 'aws-cdk-lib/aws-lightsail';
// lightsail.CfnDisk

Properties

Configuration passed to the constructor as CfnDiskProps.

diskNameRequired
string

The name of the disk.

sizeInGbRequired
number

The size of the disk in GB.

addOnsOptional
IResolvable | IResolvable | AddOnProperty[]

An array of add-ons for the disk. > If the disk has an add-on enabled when performing a delete disk request, the add-on is automatically disabled before the disk is deleted.

availabilityZoneOptional
string

The AWS Region and Availability Zone location for the disk (for example, `us-east-1a` ).

locationOptional
IResolvable | LocationProperty

The AWS Region and Availability Zone where the disk is located.

tagsOptional
CfnTag[]

An array of key-value pairs to apply to this resource. For more information, see [Tag](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-resource-tags.html) in the *AWS CloudFormation User Guide* . > The `Value` of `Tags` is optional for Lightsail resources.

CloudFormation Resource

This L1 construct maps directly to the following CloudFormation resource type.

Learn AWS the Practical Way

Our bi-weekly newsletter teaches hands-on AWS fundamentals. No certification fluff - just practical knowledge.

Subscribe to Newsletter