InstanceCloneProps
Properties for defining a InstanceClone
.
See https://www.alibabacloud.com/help/ros/developer-reference/aliyun-ecs-instanceclone
Initializer
import ros_cdk_ecs
ros_cdk_ecs.InstanceCloneProps(
source_instance_id: typing.Union[str, IResolvable],
backend_server_weight: typing.Union[typing.Union[int, float], IResolvable] = None,
deletion_protection: typing.Union[bool, IResolvable] = None,
description: typing.Union[str, IResolvable] = None,
disk_mappings: typing.Union[IResolvable, typing.List[typing.Union[IResolvable, DiskMappingsProperty]]] = None,
image_id: typing.Union[str, IResolvable] = None,
instance_charge_type: typing.Union[str, IResolvable] = None,
instance_name: typing.Union[str, IResolvable] = None,
internet_max_bandwidth_in: typing.Union[typing.Union[int, float], IResolvable] = None,
key_pair_name: typing.Union[str, IResolvable] = None,
load_balancer_id_to_attach: typing.Union[str, IResolvable] = None,
password: typing.Union[str, IResolvable] = None,
period: typing.Union[typing.Union[int, float], IResolvable] = None,
ram_role_name: typing.Union[str, IResolvable] = None,
resource_group_id: typing.Union[str, IResolvable] = None,
security_group_id: typing.Union[str, IResolvable] = None,
spot_price_limit: typing.Union[str, IResolvable] = None,
spot_strategy: typing.Union[str, IResolvable] = None,
tags: typing.List[TagsProperty] = None,
zone_id: typing.Union[str, IResolvable] = None
)
Properties
Name | Type | Description |
---|---|---|
source_instance_id |
typing.Union[str, ros_cdk_core.IResolvable] |
Property sourceInstanceId: Source ecs instance used to copy properties to clone new ecs instance. |
backend_server_weight |
typing.Union[typing.Union[int, float], ros_cdk_core.IResolvable] |
Property backendServerWeight: The weight of backend server of load balancer. |
deletion_protection |
typing.Union[bool, ros_cdk_core.IResolvable] |
Property deletionProtection: Whether an instance can be released manually through the console or API, deletion protection only support postPaid instance. |
description |
typing.Union[str, ros_cdk_core.IResolvable] |
Property description: Description of the instance, [2, 256] characters. |
disk_mappings |
typing.Union[ros_cdk_core.IResolvable, typing.List[typing.Union[ros_cdk_core.IResolvable, DiskMappingsProperty]]] |
Property diskMappings: Disk mappings to attach to instance. |
image_id |
typing.Union[str, ros_cdk_core.IResolvable] |
Property imageId: Image ID to create ecs instance. |
instance_charge_type |
typing.Union[str, ros_cdk_core.IResolvable] |
Property instanceChargeType: Instance Charge type, allowed value: Prepaid and Postpaid. |
instance_name |
typing.Union[str, ros_cdk_core.IResolvable] |
Property instanceName: Display name of the instance, [2, 128] English or Chinese characters, must start with a letter or Chinese in size, can contain numbers, '_' or '.', '-'. |
internet_max_bandwidth_in |
typing.Union[typing.Union[int, float], ros_cdk_core.IResolvable] |
Property internetMaxBandwidthIn: Max internet out band width setting, unit in Mbps(Mega bit per second). |
key_pair_name |
typing.Union[str, ros_cdk_core.IResolvable] |
Property keyPairName: SSH key pair name. |
load_balancer_id_to_attach |
typing.Union[str, ros_cdk_core.IResolvable] |
Property loadBalancerIdToAttach: After the instance is created. |
password |
typing.Union[str, ros_cdk_core.IResolvable] |
Property password: Password of created ecs instance. |
period |
typing.Union[typing.Union[int, float], ros_cdk_core.IResolvable] |
Property period: Prepaid time period. |
ram_role_name |
typing.Union[str, ros_cdk_core.IResolvable] |
Property ramRoleName: Instance RAM role name. |
resource_group_id |
typing.Union[str, ros_cdk_core.IResolvable] |
Property resourceGroupId: Resource group id. |
security_group_id |
typing.Union[str, ros_cdk_core.IResolvable] |
Property securityGroupId: Security group to create ecs instance. |
spot_price_limit |
typing.Union[str, ros_cdk_core.IResolvable] |
Property spotPriceLimit: The hourly price threshold of a instance, and it takes effect only when parameter InstanceChargeType is PostPaid. |
spot_strategy |
typing.Union[str, ros_cdk_core.IResolvable] |
Property spotStrategy: The spot strategy of a Pay-As-You-Go instance, and it takes effect only when parameter InstanceChargeType is PostPaid. |
tags |
typing.List[TagsProperty] |
Property tags: Tags to attach to instance. |
zone_id |
typing.Union[str, ros_cdk_core.IResolvable] |
Property zoneId: The ID of the zone to which the instance belongs. |
source_instance_id
Required
source_instance_id: typing.Union[str, IResolvable]
- Type: typing.Union[str, ros_cdk_core.IResolvable]
Property sourceInstanceId: Source ecs instance used to copy properties to clone new ecs instance.
It will copy the InstanceType, ImageId, InternetChargeType, InternetMaxBandwidthIn, InternetMaxBandwidthOut and the system disk and data disk configurations. If the instance network is VPC, it will also clone the relative properties. If specified instance with more than one security group, it will use the first security group to create instance. you can also specify the SecurityGroupId to override it.
backend_server_weight
Optional
backend_server_weight: typing.Union[typing.Union[int, float], IResolvable]
- Type: typing.Union[typing.Union[int, float], ros_cdk_core.IResolvable]
Property backendServerWeight: The weight of backend server of load balancer.
From 0 to 100, 0 means offline. Default is 100.
deletion_protection
Optional
deletion_protection: typing.Union[bool, IResolvable]
- Type: typing.Union[bool, ros_cdk_core.IResolvable]
Property deletionProtection: Whether an instance can be released manually through the console or API, deletion protection only support postPaid instance.
description
Optional
description: typing.Union[str, IResolvable]
- Type: typing.Union[str, ros_cdk_core.IResolvable]
Property description: Description of the instance, [2, 256] characters.
Do not fill or empty, the default is empty.
disk_mappings
Optional
disk_mappings: typing.Union[IResolvable, typing.List[typing.Union[IResolvable, DiskMappingsProperty]]]
- Type: typing.Union[ros_cdk_core.IResolvable, typing.List[typing.Union[ros_cdk_core.IResolvable, DiskMappingsProperty]]]
Property diskMappings: Disk mappings to attach to instance.
Max support 16 disks. If the image contains a data disk, you can specify other parameters of the data disk via the same value of parameter "Device". If parameter "Category" is not specified, it will be cloud_efficiency instead of "Category" of data disk in the image.
image_id
Optional
image_id: typing.Union[str, IResolvable]
- Type: typing.Union[str, ros_cdk_core.IResolvable]
Property imageId: Image ID to create ecs instance.
instance_charge_type
Optional
instance_charge_type: typing.Union[str, IResolvable]
- Type: typing.Union[str, ros_cdk_core.IResolvable]
Property instanceChargeType: Instance Charge type, allowed value: Prepaid and Postpaid.
If specified Prepaid, please ensure you have sufficient balance in your account. Or instance creation will be failure. Default value is Postpaid.
instance_name
Optional
instance_name: typing.Union[str, IResolvable]
- Type: typing.Union[str, ros_cdk_core.IResolvable]
Property instanceName: Display name of the instance, [2, 128] English or Chinese characters, must start with a letter or Chinese in size, can contain numbers, '_' or '.', '-'.
internet_max_bandwidth_in
Optional
internet_max_bandwidth_in: typing.Union[typing.Union[int, float], IResolvable]
- Type: typing.Union[typing.Union[int, float], ros_cdk_core.IResolvable]
Property internetMaxBandwidthIn: Max internet out band width setting, unit in Mbps(Mega bit per second).
The range is [0,200], default is 200 Mbps.
key_pair_name
Optional
key_pair_name: typing.Union[str, IResolvable]
- Type: typing.Union[str, ros_cdk_core.IResolvable]
Property keyPairName: SSH key pair name.
load_balancer_id_to_attach
Optional
load_balancer_id_to_attach: typing.Union[str, IResolvable]
- Type: typing.Union[str, ros_cdk_core.IResolvable]
Property loadBalancerIdToAttach: After the instance is created.
Automatic attach it to the load balancer.
password
Optional
password: typing.Union[str, IResolvable]
- Type: typing.Union[str, ros_cdk_core.IResolvable]
Property password: Password of created ecs instance.
Must contain at least 3 types of special character, lower character, upper character, number.
period
Optional
period: typing.Union[typing.Union[int, float], IResolvable]
- Type: typing.Union[typing.Union[int, float], ros_cdk_core.IResolvable]
Property period: Prepaid time period.
Unit is month, it could be from 1 to 9 or 12, 24, 36, 48, 60. Default value is 1.
ram_role_name
Optional
ram_role_name: typing.Union[str, IResolvable]
- Type: typing.Union[str, ros_cdk_core.IResolvable]
Property ramRoleName: Instance RAM role name.
The name is provided and maintained by Resource Access Management (RAM) and can be queried using ListRoles. For more information, see RAM API CreateRole and ListRoles.
resource_group_id
Optional
resource_group_id: typing.Union[str, IResolvable]
- Type: typing.Union[str, ros_cdk_core.IResolvable]
Property resourceGroupId: Resource group id.
security_group_id
Optional
security_group_id: typing.Union[str, IResolvable]
- Type: typing.Union[str, ros_cdk_core.IResolvable]
Property securityGroupId: Security group to create ecs instance.
For classic instance need the security group not belong to VPC, for VPC instance, please make sure the security group belong to specified VPC.
spot_price_limit
Optional
spot_price_limit: typing.Union[str, IResolvable]
- Type: typing.Union[str, ros_cdk_core.IResolvable]
Property spotPriceLimit: The hourly price threshold of a instance, and it takes effect only when parameter InstanceChargeType is PostPaid.
Three decimals is allowed at most.
spot_strategy
Optional
spot_strategy: typing.Union[str, IResolvable]
- Type: typing.Union[str, ros_cdk_core.IResolvable]
Property spotStrategy: The spot strategy of a Pay-As-You-Go instance, and it takes effect only when parameter InstanceChargeType is PostPaid.
Value range: "NoSpot: A regular Pay-As-You-Go instance", "SpotWithPriceLimit: A price threshold for a spot instance, ""SpotAsPriceGo: A price that is based on the highest Pay-As-You-Go instance. "Default value: NoSpot.
tags
Optional
tags: typing.List[TagsProperty]
- Type: typing.List[TagsProperty]
Property tags: Tags to attach to instance.
Max support 20 tags to add during create instance. Each tag with two properties Key and Value, and Key is required.
zone_id
Optional
zone_id: typing.Union[str, IResolvable]
- Type: typing.Union[str, ros_cdk_core.IResolvable]
Property zoneId: The ID of the zone to which the instance belongs.
For more information, call the DescribeZones operation to query the most recent zone list. Default value is empty, which means random selection.