ALIYUN::ESS::ScalingConfiguration is used to create a scaling configuration.

Syntax

{
  "Type": "ALIYUN::ESS::ScalingConfiguration",
  "Properties": {
    "DiskMappings": List,
    "InternetMaxBandwidthIn": Integer,
    "InstanceId": String,
    "SecurityGroupId": String,
    "SystemDiskCategory": String,
    "SystemDiskSize": Integer,
    "ImageId": String,
    "InternetMaxBandwidthOut": Integer,
    "IoOptimized": String,
    "ScalingGroupId": String,
    "InternetChargeType": String,
    "InstanceType": String,
    "ScalingConfigurationName": String,
    "InstanceTypes": List,
    "KeyPairName": String,
    "UserData": String,
    "RamRoleName": String
  }
}

Properties

Name Type Required Editable Description Validity
ScalingGroupId String Yes No The ID of the scaling group to which the scaling configuration belongs. None
DiskMappings List No No The list of disks you want to attach to the ECS instance. A maximum of four disks can be attached.
InternetChargeType String No No The billing method for access over the Internet.

Valid values: PayByBandwidth and PayByTraffic.

Default value: PayByTraffic.

InternetMaxBandwidthIn Integer No No The maximum inbound bandwidth from the Internet. Unit: Mbit/s.

Valid values: 1 to 100.

Default value: 100.

InternetMaxBandwidthOut Integer No No The maximum outbound bandwidth to the Internet. Unit: Mbit/s.

Valid values in PayByBandwidth mode: 0 to 200. Default value: 0.

Valid values in PayByTraffic mode: 1 to 200. You must specify this parameter if you choose to use the PayByTraffic mode.

InstanceId String No No The ID of the ECS instance whose properties are used to create the scaling configuration. None
SystemDiskCategory String No No The type of a system disk. Valid values: cloud, cloud_efficiency, cloud_ssd, and ephemeral_ssd.
ImageId String No No The ID of the image used to start the ECS instance. You can use public images, custom images, and Alibaba Cloud Marketplace images. For more information, see Public images for ECS instances.
InstanceType String No No The type of the ECS instance. For more information, see ECS instance types .
SecurityGroupId String No No The ID of the security group to which the created instance belongs. None
IoOptimized String No No This parameter specifies whether to create an I/O optimized instance.

Valid values: none (non-I/O optimized) and optimized (I/O optimized).

Default value: none.

ScalingConfigurationName String No No The name of the scaling configuration. The name must be 2 to 40 characters in length and can contain letters, numbers, and special characters including underscores (_), hyphens (-), and periods (.). The name must be unique in a scaling group. Default value: ScalingConfigurationId.
KeyPairName String No No The name of the key pair that is used to connect to the ECS instance. For Windows-based instances, the KeyPairName parameter is inapplicable. For Windows-based instances, this parameter is empty by default. For Linux-based instances, the Password parameter still takes effect if this parameter is specified. However, logon by password is disabled, and the KeyPairName value is used.
RamRoleName String No No The RAM role name of the instance. You can call the ListRoles API to query the role name. For more information, see CreateRole and ListRoles .
SystemDiskSize Integer No Yes The size of the system disk. Valid values: 40 to 500. Unit: GB. If a custom image is used to create a system disk, make sure that the system disk size is greater than the image size.
UserData String No No The user information you provide when you create an ECS instance. The size of the user data is limited to 16 KB. You need to convert the data into Base64-encoded strings. If the data contains special characters, add a backslash (\) immediately before each special character to indicate that it needs to be translated into the regular text.
InstanceTypes List No No The ECS instance types that can be used in a scaling group. You can specify a maximum of 10 ECS instance types. If you set this parameter, the InstanceType parameter becomes inapplicable.
PasswordInherit Boolean No Yes This parameter indicates whether to use the password predefined in the image you select. When you set this parameter, ensure that the selected image has a predefined password. None
Tags Map No Yes The tags of the instance. A tag is a key-value pair. You can specify a maximum of five sets of tags. The format is: {"key1":"value1","key2":"value2", ... "key5":"value5"}. The following rules apply to keys and values:
  • A key can contain a maximum of 64 characters and cannot start with aliyun, http://, or https://. You cannot specify an empty string for a key.
  • A value can contain a maximum of 128 characters and cannot start with aliyun, http://, or https://. You can specify an empty string for a value.
None
SpotStrategy String No Yes The spot strategy for a Pay-As-You-Go instance. Valid values:
  • NoSpot: indicates a regular Pay-As-You-Go instance.
  • SpotWithPriceLimit: indicates a preemptible instance with the maximum hourly price.
  • SpotAsPriceGo: indicates a Pay-As-You-Go instance with its price based on the market price at the time of purchase.

Default value: NoSpot.

Valid values: NoSpot, SpotWithPriceLimit, and SpotAsPriceGo.
InstanceName String No Yes The name of an ECS instance that is created based on the current scaling configuration. None
SpotPriceLimit Number No Yes The maximum hourly price for a preemptible instance. This parameter is applicable only when the SpotStrategy parameter is set to SpotWithPriceLimit. Three decimal places are allowed at most. The default value of InstanceTypes can be overwritten by the value of SpotPriceLimitForInstanceType. None
SpotPriceLimitForInstanceType Map No Yes The type of a preemptible instance. This parameter is applicable only when the SpotStrategy parameter is set to SpotWithPriceLimit. For example, {"key1":"value1","key2":"value2",…“key5 ”,“value5 ”}.

A key is an ECS instance type. A value can have a maximum of three decimal places.

None

DiskMappings syntax

"DiskMappings": [
  {
    "Category": String,
    "DiskName": String,
    "Description": String,
    "Device": String,
    "SnapshotId": String,
    "Size": String
  }
]

DiskMappings properties

Name Type Required Editable Description Validity
Size String Yes No The size of a data disk. Unit: GB. None
Category String No No The type of the data disk. Valid values: cloud, cloud_efficiency, cloud_ssd, and ephemeral_ssd.
DiskName String No No The name of the data disk. The name must be 1 to 128 characters in length and can contain letters, digits, underscores (_), hyphens (-), and periods (.).
Description String No No The description of the data disk. The description must be 2 to 256 characters in length. This parameter is empty by default.
Device String No No The device name of the data disk in the ECS instance. Example: /dev/xvd[a-z].
SnapshotId String No No The ID of the snapshot used to create the data disk. None

Response parameters

Fn::GetAtt

ScalingConfigurationId: the ID of the scaling configuration. It is a globally unique identifier (GUID) generated by the system.

Examples

{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Resources": {
    "ScalingConfiguration": {
      "Type": "ALIYUN::ESS::ScalingConfiguration",
      "Properties": {
        "ImageId": "ubuntu1404_64_20G_aliaegis_20150325.vhd",
        "InstanceType": "ecs.t1.small",
        "InstanceId": "i-25xhhcqbu",
        "InternetChargeType": "PayByTraffic",
        "InternetMaxBandwidthIn": 1,
        "InternetMaxBandwidthOut": 20,
        "SystemDisk_Category": "cloud",
        "ScalingGroupId": "bwhtvpcBcKYac9fe3vd0kv7E",
        "SecurityGroupId": "sg-25zwc3se0",
        "DiskMappings": [
          {
            "Size": 10
          },
          {
            "Category": "cloud",
            "Size": 10
          }
        ]
      }
    }
  },
  "Outputs": {
    "ScalingConfiguration": {
      "Value": {"get_attr": ["ScalingConfigurationId"]}
    }
  }
}