DATASOURCE::ECS::DiskCategories is used to query the disk types and categories.

Syntax

{
  "Type": "DATASOURCE::ECS::DiskCategories",
  "Properties": {
    "Type": String,
    "ZoneId": String,
    "DataDiskCategory": String,
    "InstanceType": String,
    "SystemDiskCategory": String
  }
}

Properties

PropertyTypeRequiredEditableDescriptionConstraint
TypeStringYesYesThe type of the disk that you want to query. Valid values:
  • system: system disk
  • data: data disk
ZoneIdStringYesYesThe ID of the zone. None.
DataDiskCategoryStringNoYesThe category of the data disk. Valid values:
  • cloud: basic disk
  • cloud_efficiency: ultra disk
  • cloud_ssd: standard SSD
  • ephemeral_ssd: local SSD
  • cloud_essd: enhanced SSD (ESSD)
Note This property takes effect when you set the Type property to data.
InstanceTypeStringNoYesThe Elastic Compute Service (ECS) instance type. For more information, see Overview of instance families and DescribeInstanceTypes.
SystemDiskCategoryStringNoYesThe category of the system disk. Valid values:
  • cloud: basic disk
  • cloud_efficiency: ultra disk
  • cloud_ssd: standard SSD
  • ephemeral_ssd: local SSD
  • cloud_essd: ESSD
Note This property takes effect when you set the Type property to system.

Return values (Fn::GetAtt)

  • DiskCategoryIds: the disk categories.
  • DiskCategories: details of the disk types and categories.
PropertyTypeDescriptionConstraint
DiskCategoryIdsListThe disk categories. Example: ["cloud_ssd", "cloud_essd", "cloud_efficiency"].
DiskCategoriesListDetails of the disk types and categories. None.
TypeStringThe type of the disk. Valid values:
  • system: system disk
  • data: data disk
DiskCategoryStringThe category of the disk. Valid values:
  • cloud: basic disk
  • cloud_efficiency: ultra disk
  • cloud_ssd: standard SSD
  • ephemeral_ssd: local SSD
  • cloud_essd: ESSD

Examples

  • YAMLformat

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      ZoneId:
        AssociationProperty: ALIYUN::ECS::Instance::ZoneId
        Type: String
        Description: The ID of the zone for which to query resources.
    Resources:
      ExtensionDataSource:
        Type: DATASOURCE::ECS::DiskCategories
        Properties:
          SystemDiskCategory: cloud_essd
          Type: data
          ZoneId:
            Ref: ZoneId
    Outputs:
      DiskCategoryIds:
        Description: The list of disk category IDs.
        Value:
          Fn::GetAtt:
            - ExtensionDataSource
            - DiskCategoryIds
      DiskCategories:
        Description: The list of disk categories.
        Value:
          Fn::GetAtt:
            - ExtensionDataSource
            - DiskCategories
    
  • JSONformat

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "ZoneId": {
          "AssociationProperty": "ALIYUN::ECS::Instance::ZoneId",
          "Type": "String",
          "Description": "The ID of the zone for which to query resources."
        }
      },
      "Resources": {
        "ExtensionDataSource": {
          "Type": "DATASOURCE::ECS::DiskCategories",
          "Properties": {
            "SystemDiskCategory": "cloud_essd",
            "Type": "data",
            "ZoneId": {
              "Ref": "ZoneId"
            }
          }
        }
      },
      "Outputs": {
        "DiskCategoryIds": {
          "Description": "The list of disk category IDs.",
          "Value": {
            "Fn::GetAtt": [
              "ExtensionDataSource",
              "DiskCategoryIds"
            ]
          }
        },
        "DiskCategories": {
          "Description": "The list of disk categories.",
          "Value": {
            "Fn::GetAtt": [
              "ExtensionDataSource",
              "DiskCategories"
            ]
          }
        }
      }
    }