AWS::Lightsail::Disk - Amazon CloudFormation
Services or capabilities described in Amazon Web Services documentation might vary by Region. To see the differences applicable to the China Regions, see Getting Started with Amazon Web Services in China (PDF).


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


To declare this entity in your Amazon CloudFormation template, use the following syntax:


{ "Type" : "AWS::Lightsail::Disk", "Properties" : { "AddOns" : [ AddOn, ... ], "AvailabilityZone" : String, "DiskName" : String, "Location" : Location, "SizeInGb" : Integer, "Tags" : [ Tag, ... ] } }


Type: AWS::Lightsail::Disk Properties: AddOns: - AddOn AvailabilityZone: String DiskName: String Location: Location SizeInGb: Integer Tags: - Tag



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.

Required: No

Type: Array of AddOn

Update requires: No interruption


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

Required: No

Type: String

Minimum: 1

Maximum: 255

Update requires: Updates are not supported.


The name of the disk.

Required: Yes

Type: String

Pattern: ^[a-zA-Z0-9][\w\-.]*[a-zA-Z0-9]$

Minimum: 1

Maximum: 254

Update requires: Replacement


The Amazon Web Services Region and Availability Zone where the disk is located.

Required: No

Type: Location

Update requires: No interruption


The size of the disk in GB.

Required: Yes

Type: Integer

Update requires: Updates are not supported.


An array of key-value pairs to apply to this resource.

For more information, see Tag in the Amazon CloudFormation User Guide.


The Value of Tags is optional for Lightsail resources.

Required: No

Type: Array of Tag

Update requires: No interruption

Return values


When you pass the logical ID of this resource to the intrinsic Ref function, Ref returns a unique identifier for this resource.


The Fn::GetAtt intrinsic function returns a value for a specified attribute of this type. The following are the available attributes and sample return values.

For more information about using the Fn::GetAtt intrinsic function, see Fn::GetAtt.


The resources to which the disk is attached.


(Deprecated) The attachment state of the disk.


In releases prior to November 14, 2017, this parameter returned attached for system disks in the API response. It is now deprecated, but still included in the response. Use isAttached instead.


The Amazon Resource Name (ARN) of the disk.


The input/output operations per second (IOPS) of the disk.


A Boolean value indicating whether the disk is attached.


The Availability Zone where the disk is located.


The Amazon Web Services Region where the disk is located.


The disk path.


The resource type of the disk (for example, Disk).


The state of the disk (for example, in-use).


The support code of the disk.

Include this code in your email to support when you have questions about a disk or another resource in Lightsail. This code helps our support team to look up your Lightsail information.


Availability Zone

You can specify an Availability Zone when you perform a create disk request. If you don’t specify one, the disk is created in the same Availability Zone as the last Lightsail resource you created.

Disk state

Disks can be deleted only when they're in an available state. If the disk is in an attached state when performing a delete disk request, the service will wait to check if the disk state changes to available. The delete disk request times out if the disk state doesn't change to available within 15 minutes.