CfnDiskPropsMixin
- class aws_cdk.mixins_preview.aws_lightsail.mixins.CfnDiskPropsMixin(props, *, strategy=None)
Bases:
MixinThe
AWS::Lightsail::Diskresource specifies a disk that can be attached to an Amazon Lightsail instance that is in the same AWS Region and Availability Zone.- See:
http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-lightsail-disk.html
- CloudformationResource:
AWS::Lightsail::Disk
- Mixin:
true
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview import mixins from aws_cdk.mixins_preview.aws_lightsail import mixins as lightsail_mixins cfn_disk_props_mixin = lightsail_mixins.CfnDiskPropsMixin(lightsail_mixins.CfnDiskMixinProps( add_ons=[lightsail_mixins.CfnDiskPropsMixin.AddOnProperty( add_on_type="addOnType", auto_snapshot_add_on_request=lightsail_mixins.CfnDiskPropsMixin.AutoSnapshotAddOnProperty( snapshot_time_of_day="snapshotTimeOfDay" ), status="status" )], availability_zone="availabilityZone", disk_name="diskName", location=lightsail_mixins.CfnDiskPropsMixin.LocationProperty( availability_zone="availabilityZone", region_name="regionName" ), size_in_gb=123, tags=[CfnTag( key="key", value="value" )] ), strategy=mixins.PropertyMergeStrategy.OVERRIDE )
Create a mixin to apply properties to
AWS::Lightsail::Disk.- Parameters:
props (
Union[CfnDiskMixinProps,Dict[str,Any]]) – L1 properties to apply.strategy (
Optional[PropertyMergeStrategy]) – (experimental) Strategy for merging nested properties. Default: - PropertyMergeStrategy.MERGE
Methods
- apply_to(construct)
Apply the mixin properties to the construct.
- Parameters:
construct (
IConstruct)- Return type:
- supports(construct)
Check if this mixin supports the given construct.
- Parameters:
construct (
IConstruct)- Return type:
bool
Attributes
- CFN_PROPERTY_KEYS = ['addOns', 'availabilityZone', 'diskName', 'location', 'sizeInGb', 'tags']
Static Methods
- classmethod is_mixin(x)
(experimental) Checks if
xis a Mixin.- Parameters:
x (
Any) – Any object.- Return type:
bool- Returns:
true if
xis an object created from a class which extendsMixin.- Stability:
experimental
AddOnProperty
- class CfnDiskPropsMixin.AddOnProperty(*, add_on_type=None, auto_snapshot_add_on_request=None, status=None)
Bases:
objectAddOnis a property of the AWS::Lightsail::Disk resource. It describes the add-ons for a disk.- Parameters:
add_on_type (
Optional[str]) – The add-on type (for example,AutoSnapshot). .. epigraph::AutoSnapshotis the only add-on that can be enabled for a disk.auto_snapshot_add_on_request (
Union[IResolvable,AutoSnapshotAddOnProperty,Dict[str,Any],None]) – The parameters for the automatic snapshot add-on, such as the daily time when an automatic snapshot will be created.status (
Optional[str]) – The status of the add-on. Valid Values:Enabled|Disabled
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_lightsail import mixins as lightsail_mixins add_on_property = lightsail_mixins.CfnDiskPropsMixin.AddOnProperty( add_on_type="addOnType", auto_snapshot_add_on_request=lightsail_mixins.CfnDiskPropsMixin.AutoSnapshotAddOnProperty( snapshot_time_of_day="snapshotTimeOfDay" ), status="status" )
Attributes
- add_on_type
The add-on type (for example,
AutoSnapshot).AutoSnapshotis the only add-on that can be enabled for a disk.
- auto_snapshot_add_on_request
The parameters for the automatic snapshot add-on, such as the daily time when an automatic snapshot will be created.
- status
The status of the add-on.
Valid Values:
Enabled|Disabled
AutoSnapshotAddOnProperty
- class CfnDiskPropsMixin.AutoSnapshotAddOnProperty(*, snapshot_time_of_day=None)
Bases:
objectAutoSnapshotAddOnis a property of the AddOn property. It describes the automatic snapshot add-on for a disk.- Parameters:
snapshot_time_of_day (
Optional[str]) – The daily time when an automatic snapshot will be created. Constraints: - Must be inHH:00format, and in an hourly increment. - Specified in Coordinated Universal Time (UTC). - The snapshot will be automatically created between the time specified and up to 45 minutes after.- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_lightsail import mixins as lightsail_mixins auto_snapshot_add_on_property = lightsail_mixins.CfnDiskPropsMixin.AutoSnapshotAddOnProperty( snapshot_time_of_day="snapshotTimeOfDay" )
Attributes
- snapshot_time_of_day
The daily time when an automatic snapshot will be created.
Constraints:
Must be in
HH:00format, and in an hourly increment.Specified in Coordinated Universal Time (UTC).
The snapshot will be automatically created between the time specified and up to 45 minutes after.
LocationProperty
- class CfnDiskPropsMixin.LocationProperty(*, availability_zone=None, region_name=None)
Bases:
objectThe AWS Region and Availability Zone where the disk is located.
- Parameters:
availability_zone (
Optional[str]) – The Availability Zone where the disk is located.region_name (
Optional[str]) – The AWS Region where the disk is located.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_lightsail import mixins as lightsail_mixins location_property = lightsail_mixins.CfnDiskPropsMixin.LocationProperty( availability_zone="availabilityZone", region_name="regionName" )
Attributes
- availability_zone
The Availability Zone where the disk is located.
- region_name
The AWS Region where the disk is located.