全部产品
Search
文档中心

资源编排:AssociationProperty和AssociationPropertyMetadata

更新时间:Jan 24, 2024

当您使用ROS创建资源栈管理多种资源时,通常需要打开多个控制台查找资源参数信息。此时您可以在模板的参数配置中指定AssociationProperty以获取所选地域下对应的资源,指定AssociationPropertyMetadata对不同参数添加筛选条件,以便在控制台动态选择参数配置。

参数说明

AssociationPropertyMetadata参数的取值:

  • 为参数指定特定值。例如:"RegionId": "cn-hangzhou",ROS将填入特定的地域cn-hangzhou。

  • 为参数指定变量,格式为${ParameterKey}。例如:"VpcId": "${VpcId}",ROS将动态获取当前模板中参数VpcId对应的值。

    说明
    • 如果需要将${ParameterKey}指定为固定值,可以增加感叹号(!)。例如:${!Literal}表示取值为${Literal}

    • 如果要在Terraform模板中使用参数变量,需要在$前增加一个$。例如:"VpcId": "$${VpcId}",ROS将动态获取Terraform模板中VpcId对应的值。

ROS支持的AssociationProperty和对应的AssociationPropertyMetadata如下表所示。

AssociationProperty取值

说明

对应的AssociationPropertyMetadata

Password

密码输入。

TextArea

富文本输入。

Json

JSON对象输入。

CommaDelimitedList

输入用逗号分隔的数组。

Code

代码输入。

FileContent

从本地文件读取内容。

AcceptFileSuffixes:接受上传的文件类型。多个文件类型之间用半角逗号分隔开。

Cron

Cron表达式,指定定时任务执行时间的格式化字符串。

ChargeType

付费类型。取值:

  • 按量付费。

  • 包年包月。

Auto

ROS会基于Terraform原始数据结构,自动生成AssociationProperty和AssociationPropertyMetadata等字段。

说明

仅对Terraform类型模板的Json类型参数生效。

Overwrite:补充或覆盖内层嵌套参数的定义。

该参数可选,为字典类型,组成部分如下:

  • 内层嵌套参数的路径。路径规则如下:

    • 若要表示list或set中的元素,添加*

    • 若要表示object中的某一项,添加该项的名称。

    • 路径使用.分隔。

    • 开头和中间的*可以省略。结尾的一个或多个*不能省略。

    示例如下:

    // name的路径为name。
    // address的路径为address。
    variable "user_information" {
      type = object({
        name    = string
        address = string
      })
    }
    
    // region_ids中元素的路径为*。
    variable "region_ids" {
      type    = list(string)
    }
    
    // internal的路径为*.internal,可简写为internal。
    // external的路径为*.external,可简写为external。
    // protocol的路径为*.protocol,可简写为protocol。
    variable "docker_ports" {
      type = list(object({
        internal = number
        external = number
        protocol = string
      }))
    }
    
    // b的路径为 *.b,可简写为b。
    // b中元素的路径为*.b.*,可简写为b.*
    // c的路径为*.c,可简写为c。
    // d的路径为*.c.*.d,可简写为c.d。
    // d中元素的路径为*.c.*.d.*,可简写为c.d.*。
    // e的路径为*.e,可简写为e。
    // e中元素的路径为*.e.*,可简写为e.*。
    // e中元素的路径为*.e.*.*,可简写为e.*.*(必须保留两个*)。
    // f的路径为*.f,可简写为f。
    // g的路径为*.f.*.*.g,可简写为f.g。
    // g中元素的路径为*.f.*.*.g.*,可简写为f.g.*。
    variable "complex_type_demo" {
      type = list(object({
        b = list(string)
        c = list(object({
          d = list(string)
        }))
        e = list(list(string))
        f = list(list(object({
          g = list(string)
        })))
      }))
    }
  • 参数定义的补充。更多信息,请参见概览

List[Parameter]

参数列表。使用缩进排布。

仅对Json类型参数生效。

Parameter:参数定义。

更多信息,请参见概览

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionIds": {
          "Label": {
            "en": "ECS Region Ids",
            "zh-cn": "ECS地域列表"
          },
          "MaxLength": 100,
          "MinLength": 1,
          "Type": "Json",
          "AssociationProperty": "List[Parameter]",
          "AssociationPropertyMetadata": {
            "Parameter": {
              "Type": "String",
              "AssociationProperty": "ALIYUN::ECS::RegionId",
              "MinLength": 1,
              "MaxLength": 64
            }
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionIds:
        Label:
          en: ECS Region Ids
          zh-cn: ECS地域列表
        MaxLength: 100
        MinLength: 1
        Type: Json
        AssociationProperty: List[Parameter]
        AssociationPropertyMetadata:
          Parameter:
            Type: String
            AssociationProperty: ALIYUN::ECS::RegionId
            MinLength: 1
            MaxLength: 64
  • 示例说明

    示例中通过指定AssociationProperty为List[Parameter],AssociationPropertyMetadata为Parameter,实现多个ECS地域ID在控制台缩进排布的效果。

使用缩进排布。

仅对Json类型参数生效。

说明

不指定AssociationProperty,仅指定AssociationPropertyMetadata,为参数实现缩进排布。

  • Parameters:字典类型,表示一组参数定义。

    • 键:参数名。

    • 值:参数定义。更多信息,请参见概览

    示例如下:

    • 示例代码

      JSON示例:

      {
        "ROSTemplateFormatVersion": "2015-09-01",
        "Parameters": {
          "RenameECS": {
            "Label": {
              "en": "Rename ECS",
              "zh-cn": "重命名ECS"
            },
            "MaxLength": 100,
            "MinLength": 1,
            "Type": "Json",
            "AssociationPropertyMetadata": {
              "Parameters": {
                "InstanceId": {
                  "Type": "String",
                  "Label": {
                    "en": "ECS Instance Id",
                    "zh-cn": "ECS实例ID"
                  },
                  "AssociationProperty": "ALIYUN::ECS::Instance::InstanceId",
                  "MinLength": 1,
                  "MaxLength": 64
                },
                "Name": {
                  "Type": "String",
                  "Label": {
                    "en": "New Name",
                    "zh-cn": "新名称"
                  },
                  "MinLength": 1
                }
              }
            }
          }
        }
      }

      YAML示例:

      ROSTemplateFormatVersion: '2015-09-01'
      Parameters:
        RenameECS:
          Label:
            en: Rename ECS
            zh-cn: 重命名ECS
          MaxLength: 100
          MinLength: 1
          Type: Json
          AssociationPropertyMetadata:
            Parameters:
              InstanceId:
                Type: String
                Label:
                  en: ECS Instance Id
                  zh-cn: ECS实例ID
                AssociationProperty: ALIYUN::ECS::Instance::InstanceId
                MinLength: 1
                MaxLength: 64
              Name:
                Type: String
                Label:
                  en: New Name
                  zh-cn: 新名称
                MinLength: 1
    • 示例说明

      示例中不指定AssociationProperty,仅指定AssociationPropertyMetadata为Parameters,实现单个ECS实例ID在控制台缩进排布的效果。

  • Metadata:字典类型。更多信息,请参见元数据(Metadata)

说明

结合List[Parameter]可以实现嵌套结构,且对于嵌套深度没有限制。

List[Parameters]

参数组列表。使用表格排布。

仅对Json类型参数生效。

  • Parameters:字典类型,必选,表示一组参数定义。

    • 键:参数名。

    • 值:参数定义。更多信息,请参见概览

      说明

      由于使用表格排布,建议使用简单类型参数,不建议进行嵌套。

    示例如下:

    • 示例代码

      JSON示例:

      {
        "ROSTemplateFormatVersion": "2015-09-01",
        "Parameters": {
          "RenameECS": {
            "Label": {
              "en": "Rename ECS",
              "zh-cn": "重命名ECS"
            },
            "MaxLength": 100,
            "MinLength": 1,
            "Type": "Json",
            "AssociationProperty": "List[Parameters]",
            "AssociationPropertyMetadata": {
              "Parameters": {
                "InstanceId": {
                  "Type": "String",
                  "Label": {
                    "en": "ECS Instance Id",
                    "zh-cn": "ECS实例ID"
                  },
                  "AssociationProperty": "ALIYUN::ECS::Instance::InstanceId",
                  "MinLength": 1,
                  "MaxLength": 64
                },
                "Name": {
                  "Type": "String",
                  "Label": {
                    "en": "New Name",
                    "zh-cn": "新名称"
                  },
                  "MinLength": 1
                }
              }
            }
          }
        }
      }

      YAML示例:

      ROSTemplateFormatVersion: '2015-09-01'
      Parameters:
        RenameECS:
          Label:
            en: Rename ECS
            zh-cn: 重命名ECS
          MaxLength: 100
          MinLength: 1
          Type: Json
          AssociationProperty: List[Parameters]
          AssociationPropertyMetadata:
            Parameters:
              InstanceId:
                Type: String
                Label:
                  en: ECS Instance Id
                  zh-cn: ECS实例ID
                AssociationProperty: ALIYUN::ECS::Instance::InstanceId
                MinLength: 1
                MaxLength: 64
              Name:
                Type: String
                Label:
                  en: New Name
                  zh-cn: 新名称
                MinLength: 1
    • 示例说明

      示例中通过指定AssociationProperty为List[Parameters],AssociationPropertyMetadata为Parameters,实现多个ECS实例ID在控制台表格排布的效果。

  • ListMetadata:字典类型,用于控制表格显示。

    • ShowHeader:枚举类型,表示是否显示表头。默认值:true。

    • ShowRemove:枚举类型,表示是否显示移除按钮。默认值:true。

    • ShowAddition:枚举类型,表示是否新增按钮。默认值:true。

    • Order:字符串列表,表示表格从左到右每列对应的参数。默认所有参数按字母序排列显示。

DateTime

日期。

  • GMTZone:GMT可用区。

  • TimeZone:时区描述。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "DateTime": {
          "Type": "String",
          "AssociationProperty": "DateTime"
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      DateTime:
        Type: String
        AssociationProperty: DateTime
  • 示例说明

    示例中通过指定参数DateTime的AssociationProperty为DateTime,来设置日期。

GMTZone

GMT可用区选择。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "GMTZone": {
          "Type": "String",
          "AssociationProperty": "GMTZone"
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      GMTZone:
        Type: String
        AssociationProperty: GMTZone
  • 示例说明

    示例中通过指定参数GMTZone的AssociationProperty属性为GMTZone,设置GMT可用区。

OOSServiceRole

OOS的服务角色。

RegionId:地域ID(默认为资源栈所属地域)。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "OosServiceRole": {
          "Type": "String",
          "AssociationProperty": "OOSServiceRole",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例;

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      OosServiceRole:
        Type: String
        AssociationProperty: OOSServiceRole
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数OosServiceRole的AssociationProperty属性为OOSServiceRole,设置OOS的服务角色。

RateControl

OOS的执行速率。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RateControl": {
          "Type": "String",
          "AssociationProperty": "RateControl"
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RateControl:
        Type: String
        AssociationProperty: RateControl
  • 示例说明

    示例中通过指定参数RateControl的AssociationProperty属性为RateControl,配置OOS执行速率。

Tags

标签。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • ResourceType:用于分组统计的资源类型。默认值:ALIYUN::ECS::INSTANCE。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "Tags": {
          "Type": "String",
          "AssociationProperty": "Tags",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}",
            "ResourceType": "ALIYUN::ECS::INSTANCE"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      Tags:
        Type: String
        AssociationProperty: Tags
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
          ResourceType: ALIYUN::ECS::INSTANCE
  • 示例说明

    示例中通过指定参数Tags的AssociationProperty属性为Tags,AssociationPropertyMetadata属性为RegionId、ResourceType,获取ECS实例的自定义标签信息。

Targets

ECS实例对象。支持通过实例ID、标签、资源组等方式选择实例。

RegionId:地域ID(默认为资源栈所属地域)。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "Targets": {
          "Type": "String",
          "AssociationProperty": "Targets",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      Targets:
        Type: String
        AssociationProperty: Targets
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数Targets的AssociationProperty属性为Targets,AssociationPropertyMetadata属性为RegionId,获取ECS实例对象。

TimeTriggerWeekly

按周选择时间。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "TimeTriggerWeekly": {
          "Type": "String",
          "AssociationProperty": "TimeTriggerWeekly"
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      TimeTriggerWeekly:
        Type: String
        AssociationProperty: TimeTriggerWeekly
  • 示例说明

    示例中通过指定参数TimeTriggerWeekly的AssociationProperty属性为TimeTriggerWeekly,实现按周选择时间。

TimeZone

时区选择。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "TimeZone": {
          "Type": "String",
          "AssociationProperty": "TimeZone"
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      TimeZone:
        Type: String
        AssociationProperty: TimeZone
  • 示例说明

    示例中通过指定参数TimeZone的AssociationProperty属性为TimeZone,来配置时区。

ALIYUN::ECS::RegionId

地域ID(默认为资源栈所属地域)。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
  • 示例说明

    示例中通过指定参数RegionId的AssociationProperty为ALIYUN::ECS::RegionId,实现列举可用地域的列表。

ZoneId

可用区ID。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • ShowRandom:展示随机分配选项。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "ZoneId": {
          "Type": "String",
          "AssociationProperty": "ZoneId",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      ZoneId:
        Type: String
        AssociationProperty: ZoneId
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数ZoneId的AssociationProperty属性为ZoneId,AssociationPropertyMetadata属性为RegionId,获取当前可用地域下的可用区列表。

ALIYUN::ECS::Instance::InstanceId

ECS实例ID。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • InstanceType:实例的规格。

  • InstanceTypeFamily:实例的规格族。

  • Platform:操作系统平台。

  • OSType:操作系统类型。

  • Status:实例状态。

  • NetworkType:实例网络类型。

  • DisabledNetworkType:禁用网络类型。

  • ShowNetworkType:展示实例网络类型。

  • InternetChargeType:公网带宽计费方式。

  • DisabledInternetChargeType:禁用公网带宽计费方式。

  • ShowInternetChargeType:展示公网带宽计费方式。

  • ChargeType:实例的计费方式。

  • DisabledChargeType:禁用实例的计费方式。

  • ShowChargeType: 展示实例的计费方式。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "InstanceId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::Instance::InstanceId",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      InstanceId:
        Type: String
        AssociationProperty: ALIYUN::ECS::Instance::InstanceId
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数InstanceId的AssociationProperty属性为ALIYUN::ECS::Instance::InstanceId,AssociationPropertyMetadata属性为RegionId,获取当前可用地域下已有云服务器ECS实例。

ALIYUN::ECS::Instance::Password

ECS实例密码组件。

说明

密码必须包含8~30个字符,必须包含大写字母、小写字母、数字和特殊字符中的三种以上。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "password": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::Instance::Password"
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      password:
        Type: String
        AssociationProperty: ALIYUN::ECS::Instance::Password
  • 示例说明

    示例中通过指定参数password的AssociationProperty属性为ALIYUN::ECS::Instance::Password,实现ECS实例密码的条件限制。

    限制条件:密码必须包含8~30个字符,必须包含大写字母、小写字母、数字和特殊字符中的三种以上。

ALIYUN::ECS::Instance::AttributeSelector

ECS属性选择器。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "AttributeSelector": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::Instance::AttributeSelector"
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      AttributeSelector:
        Type: String
        AssociationProperty: ALIYUN::ECS::Instance::AttributeSelector
  • 示例说明

    示例中通过指定参数AttributeSelector的AssociationProperty属性为ALIYUN::ECS::Instance::AttributeSelector,获取ECS属性选择器。

ALIYUN::ECS::Instance::InstancePropertyEditor

ECS实例属性编辑器。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "InstancePropertyEditor": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::Instance::InstancePropertyEditor"
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      InstancePropertyEditor:
        Type: String
        AssociationProperty: ALIYUN::ECS::Instance::InstancePropertyEditor
  • 示例说明

    示例中通过指定参数InstancePropertyEditor的AssociationProperty属性为ALIYUN::ECS::Instance::InstancePropertyEditor,获取ECS实例属性编辑器。

ALIYUN::ECS::Instance::MaxBandwidthIn

ECS公网入带宽最大值。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "MaxBandwidthIn": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::Instance::MaxBandwidthIn"
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      MaxBandwidthIn:
        Type: String
        AssociationProperty: ALIYUN::ECS::Instance::MaxBandwidthIn
  • 示例说明

    示例中通过指定参数MaxBandwidthIn的AssociationProperty属性为ALIYUN::ECS::Instance::MaxBandwidthIn,获取ECS公网入带宽最大值。

ALIYUN::ECS::Instance::RenewPeriod

ECS续费周期。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RenewPeriod": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::Instance::RenewPeriod"
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RenewPeriod:
        Type: String
        AssociationProperty: ALIYUN::ECS::Instance::RenewPeriod
  • 示例说明

    示例中通过指定参数RenewPeriod的AssociationProperty属性为ALIYUN::ECS::Instance::RenewPeriod,获取ECS续费周期。

ALIYUN::ECS::Instance::StopMode

ECS停机模式。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "StopMode": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::Instance::StopMode"
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      StopMode:
        Type: String
        AssociationProperty: ALIYUN::ECS::Instance::StopMode
  • 示例说明

    示例中通过指定参数StopMode的AssociationProperty属性为ALIYUN::ECS::Instance::StopMode,获取ECS停机模式。

ALIYUN::ECS::InstanceType::AvailableInstanceType

ECS可用实例规格。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "AvailableInstanceType": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::InstanceType::AvailableInstanceType"
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      AvailableInstanceType:
        Type: String
        AssociationProperty: ALIYUN::ECS::InstanceType::AvailableInstanceType
  • 示例说明

    示例中通过指定参数AvailableInstanceType的AssociationProperty属性为 ALIYUN::ECS::InstanceType::AvailableInstanceType,获取ECS可用实例规格。

ALIYUN::ECS::ManagedInstance::InstanceId

ECS托管实例ID。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • OsType:托管实例的操作系统类型。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "InstanceId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::ManagedInstance::InstanceId",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      InstanceId:
        Type: String
        AssociationProperty: ALIYUN::ECS::ManagedInstance::InstanceId
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数InstanceId的AssociationProperty属性为ALIYUN::ECS::ManagedInstance::InstanceId,AssociationPropertyMetadata属性为RegionId,获取当前可用地域下ECS托管实例ID。

ALIYUN::ECS::RAM::Role

ECS实例上已赋予的实例RAM角色。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "Role": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RAM::Role"
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      Role:
        Type: String
        AssociationProperty: ALIYUN::ECS::RAM::Role
  • 示例说明

    示例中通过指定参数Role的AssociationProperty属性为ALIYUN::ECS::RAM::Role,获取ECS实例上的已赋予的实例RAM角色。

ALIYUN::ECS::RegionId::TargetRegionIds

ECS实例目标地域ID。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "TargetRegionIds": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId::TargetRegionIds"
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      TargetRegionIds:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId::TargetRegionIds
  • 示例说明

    示例中通过指定参数TargetRegionIds的AssociationProperty属性为ALIYUN::ECS::RegionId::TargetRegionIds,获取ECS实例目标地域ID。

ALIYUN::ECS::Snapshot::SnapshotId

ECS实例磁盘快照ID。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • InstanceId:ECS实例ID。

  • DiskId:云盘ID。

  • Status:快照状态。

  • SnapshotType:快照创建类型。

  • Category:快照类型。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "DiskId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::Disk::DiskId"
        },
        "SnapshotId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::Snapshot::SnapshotId",
          "AssociationPropertyMetadata": {
            "DiskId": "${DiskId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      DiskId:
        Type: String
        AssociationProperty: ALIYUN::ECS::Disk::DiskId
      SnapshotId:
        Type: String
        AssociationProperty: ALIYUN::ECS::Snapshot::SnapshotId
        AssociationPropertyMetadata:
          DiskId: ${DiskId}
  • 示例说明

    示例中通过指定参数SnapshotId的AssociationProperty属性为ALIYUN::ECS::Snapshot::SnapshotId,获取ECS实例磁盘快照ID。

ALIYUN::ECS::TAG

ECS实例已经绑定标签信息。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • ResourceType:资源类型定义。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "Tag": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::TAG",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      Tag:
        Type: String
        AssociationProperty: ALIYUN::ECS::TAG
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数Tag的AssociationProperty属性为ALIYUN::ECS::TAG,获取ECS实例标签信息。

ALIYUN::ECS::VSwitch

交换机对象。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • ZoneId:可用区ID。

  • VpcId:专有网络ID。

  • InstanceType:实例类型。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "ZoneId": {
          "Type": "String",
          "AssociationProperty": "ZoneId"
        },
        "VSwitchId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::VSwitch",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}",
            "ZoneId": "${ZoneId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      ZoneId:
        Type: String
        AssociationProperty: ZoneId
      VSwitchId:
        Type: String
        AssociationProperty: ALIYUN::ECS::VSwitch
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
          ZoneId: ${ZoneId}
  • 示例说明

    示例中通过指定参数VSwitchId的AssociationProperty属性为ALIYUN::ECS::VSwitch,AssociationPropertyMetadata属性为RegionId、ZoneId,获取当前地域下所选可用交换机对象。

ALIYUN::RDS::Instance::InstanceId

RDS实例ID。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • ZoneId:可用区ID。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "ZoneId": {
          "Type": "String",
          "AssociationProperty": "ZoneId"
        },
        "RdsId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::RDS::Instance::InstanceId",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}",
            "ZoneId": "${ZoneId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      ZoneId:
        Type: String
        AssociationProperty: ZoneId
      RdsId:
        Type: String
        AssociationProperty: ALIYUN::RDS::Instance::InstanceId
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
          ZoneId: ${ZoneId}
  • 示例说明

    示例中通过指定参数RdsId的AssociationProperty属性为ALIYUN::RDS::Instance::InstanceId,AssociationPropertyMetadata属性为RegionId、ZoneId,实现获取当前可用地域的可用区下已有云数据库RDS实例列表。

ALIYUN::RDS::Engine::EngineId

RDS数据库类型。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "Engine": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::RDS::Engine::EngineId"
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      Engine:
        Type: String
        AssociationProperty: ALIYUN::RDS::Engine::EngineId
  • 示例说明

    示例中通过指定参数Engine的AssociationProperty属性为ALIYUN::RDS::Engine::EngineId,实现获取RDS数据库类型。

ALIYUN::RDS::Engine::EngineVersion

RDS数据库类型版本。

Engine:数据库类型。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "Engine": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::RDS::Engine::EngineId"
        },
        "EngineVersion": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::RDS::Engine::EngineVersion",
          "AssociationPropertyMetadata": {
            "Engine": "${Engine}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      Engine:
        Type: String
        AssociationProperty: ALIYUN::RDS::Engine::EngineId
      EngineVersion:
        Type: String
        AssociationProperty: ALIYUN::RDS::Engine::EngineVersion
        AssociationPropertyMetadata:
          Engine: ${Engine}
  • 示例说明

    示例中通过指定参数EngineVersion的AssociationProperty属性为ALIYUN::RDS::Engine::EngineVersion,AssociationPropertyMetadata属性为Engine,实现获取RDS数据库的版本。

ALIYUN::ECS::Disk::DataDiskCategory

数据盘类型。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • ZoneId:可用区ID。

  • InstanceType:实例类型。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "RegionId"
        },
        "ZoneId": {
          "Type": "String",
          "AssociationProperty": "ZoneId"
        },
        "InstanceType": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::Instance::InstanceType",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}",
            "ZoneId": "${ZoneId}"
          }
        },
        "DataDiskCategory": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::Disk::DataDiskCategory",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}",
            "ZoneId": "${ZoneId}",
            "InstanceType": "${InstanceType}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: RegionId
      ZoneId:
        Type: String
        AssociationProperty: ZoneId
      InstanceType:
        Type: String
        AssociationProperty: ALIYUN::ECS::Instance::InstanceType
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
          ZoneId: ${ZoneId}
      DataDiskCategory:
        Type: String
        AssociationProperty: ALIYUN::ECS::Disk::DataDiskCategory
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
          ZoneId: ${ZoneId}
          InstanceType: ${InstanceType}
  • 示例说明

    示例中通过指定参数DataDiskCategory的AssociationProperty属性为ALIYUN::ECS::Disk::DataDiskCategory ,AssociationPropertyMetadata属性为RegionId、ZoneId、InstanceType,获取ECS数据盘类型。

ALIYUN::ECS::Disk::SystemDiskCategory

系统盘类型。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • ZoneId:可用区ID。

  • InstanceType:实例类型。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "RegionId"
        },
        "ZoneId": {
          "Type": "String",
          "AssociationProperty": "ZoneId"
        },
        "InstanceType": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::Instance::InstanceType",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}",
            "ZoneId": "${ZoneId}"
          }
        },
        "SystemDiskCategory": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::Disk::SystemDiskCategory",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}",
            "ZoneId": "${ZoneId}",
            "InstanceType": "${InstanceType}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: RegionId
      ZoneId:
        Type: String
        AssociationProperty: ZoneId
      InstanceType:
        Type: String
        AssociationProperty: ALIYUN::ECS::Instance::InstanceType
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
          ZoneId: ${ZoneId}
      SystemDiskCategory:
        Type: String
        AssociationProperty: ALIYUN::ECS::Disk::SystemDiskCategory
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
          ZoneId: ${ZoneId}
          InstanceType: ${InstanceType}
  • 示例说明

    示例中通过指定参数SystemDiskCategory的AssociationProperty属性为ALIYUN::ECS::Disk::SystemDiskCategory ,AssociationPropertyMetadata属性为RegionId,ZoneId、InstanceType,获取ECS系统盘类型。

ALIYUN::ECS::Disk::DiskId

磁盘ID。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • ZoneId:可用区ID。

  • InstanceId:实例ID。

  • DiskType:磁盘类型。

  • Category:实例类型。

  • SnapshotId:快照ID。

  • DiskChargeType:磁盘计费方式。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "DiskId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::Disk::DiskId",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      DiskId:
        Type: String
        AssociationProperty: ALIYUN::ECS::Disk::DiskId
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数DiskId的AssociationProperty属性为ALIYUN::ECS::Disk::DiskId,AssociationPropertyMetadata属性为RegionId,获取当前可用区下的ECS云盘ID。

ALIYUN::ECS::VPC::VPCId

专有网络ID。

RegionId:地域ID(默认为资源栈所属地域)。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "VpcId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::VPC::VPCId",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      VpcId:
        Type: String
        AssociationProperty: ALIYUN::ECS::VPC::VPCId
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数VpcId的AssociationProperty属性为ALIYUN::ECS::VPC::VPCId,AssociationPropertyMetadata属性为RegionId,获取当前地域下的VPC专有网络ID。

ALIYUN::VPC::VSwitch::VSwitchId

交换机ID。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • ZoneId:可用区ID。

  • VpcId:专有网络ID。

  • InstanceType:实例类型。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "ZoneId": {
          "Type": "String",
          "AssociationProperty": "ZoneId"
        },
        "VSwitchId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::VPC::VSwitch::VSwitchId",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}",
            "ZoneId": "${ZoneId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      ZoneId:
        Type: String
        AssociationProperty: ZoneId
      VSwitchId:
        Type: String
        AssociationProperty: ALIYUN::VPC::VSwitch::VSwitchId
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
          ZoneId: ${ZoneId}
  • 示例说明

    示例中通过指定参数VSwitchId的AssociationProperty属性为ALIYUN::VPC::VSwitch::VSwitchId,AssociationPropertyMetadata属性为RegionId、ZoneId,获取当前地域下所选可用的交换机ID。

ALIYUN::ECS::Instance::InstanceType

ECS实例规格。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • ZoneId:可用区ID。

  • InstanceChargeType:实例付费类型。

  • SpotStrategy:按量付费实例的竞价策略。

  • InstanceType:实例规格。

  • InstanceTypeFamily:实例规格所属的实例规格族。

  • vCPU:实例规格的vCPU内核数目。

  • Memory:实例规格的内存大小。

  • Architecture:CPU架构。

  • CustomizeFamily:自定义实例规格族。

  • CreateACKClusterParams:过滤出容器服务支持 ECS 规格。

    • NetworkPlugin:网络插件。例如:terway-eniip

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "ZoneId": {
          "Type": "String",
          "AssociationProperty": "ZoneId"
        },
        "InstanceType": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::Instance::InstanceType",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}",
            "ZoneId": "${ZoneId}",
            "CreateACKClusterParams":{
              "NetworkPlugin": "terway-eniip"
            }
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      ZoneId:
        Type: String
        AssociationProperty: ZoneId
      InstanceType:
        Type: String
        AssociationProperty: ALIYUN::ECS::Instance::InstanceType
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
          ZoneId: ${ZoneId}
          CreateACKClusterParams:
            NetworkPlugin: terway-eniip
  • 示例说明

    示例中通过指定参数InstanceType的AssociationProperty属性为ALIYUN::ECS::Instance::InstanceType,AssociationPropertyMetadata属性为RegionId、ZoneId,获取当前地域下的ECS实例规格。

ALIYUN::ECS::SecurityGroup::SecurityGroupId

安全组ID。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • VpcId:专有网络ID。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "VpcId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::VPC::VPCId",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        },
        "SecurityGroupId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::SecurityGroup::SecurityGroupId",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}",
            "VpcId": "${VpcId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      VpcId:
        Type: String
        AssociationProperty: ALIYUN::ECS::VPC::VPCId
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
      SecurityGroupId:
        Type: String
        AssociationProperty: ALIYUN::ECS::SecurityGroup::SecurityGroupId
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
          VpcId: ${VpcId}
    
  • 示例说明

    示例中通过指定参数SecurityGroupId的AssociationProperty属性为ALIYUN::ECS::SecurityGroup::SecurityGroupId,AssociationPropertyMetadata属性为RegionId、VpcId,获取当前地域下所选专有网络下的安全组ID。

ALIYUN::ECS::KeyPair::KeyPairName

密钥对。

RegionId:地域ID(默认为资源栈所属地域)。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "KeyPairName": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::KeyPair::KeyPairName",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      KeyPairName:
        Type: String
        AssociationProperty: ALIYUN::ECS::KeyPair::KeyPairName
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数KeyPairName的AssociationProperty属性为ALIYUN::ECS::KeyPair::KeyPairName ,AssociationPropertyMetadata属性为RegionId,获取当前地域下的ECS密钥对。

ALIYUN::ECS::Snapshot::AutoSnapshotPolicyId

快照策略ID。

RegionId:地域ID(默认为资源栈所属地域)。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "AutoSnapshotPolicyId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::Snapshot::AutoSnapshotPolicyId",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      AutoSnapshotPolicyId:
        Type: String
        AssociationProperty: ALIYUN::ECS::Snapshot::AutoSnapshotPolicyId
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数AutoSnapshotPolicyId的AssociationProperty属性为ALIYUN::ECS::Snapshot::AutoSnapshotPolicyId,AssociationPropertyMetadata属性为RegionId,获取当前地域下的ECS自动快照策略。

ALIYUN::ECS::Command::CommandId

云助手命令或阿里云命令ID。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • ImageId:镜像ID。

    通过镜像的OSType来限制需要显示的命令的类型。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "CommandId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::Command::CommandId",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      CommandId:
        Type: String
        AssociationProperty: ALIYUN::ECS::Command::CommandId
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数CommandId的AssociationProperty属性为ALIYUN::ECS::Command::CommandId,AssociationPropertyMetadata属性为RegionId,获取当前地域下的ECS云助手命令或者阿里云提供的公共命令。

ALIYUN::ECS::Image::ImageId

镜像ID。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • SupportedImageOwnerAlias:支持的镜像类型。

  • InstanceType:实例的规格。

  • ImageFamily:镜像族系名称。

  • IsSupportIoOptimized:镜像是否可以运行在I/O优化实例上。

  • OSType:操作系统类型。

  • Architecture:镜像的体系架构。

  • Usage:镜像是否已经运行在ECS实例中。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "ImageId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::Image::ImageId",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}",
            "SupportedImageOwnerAlias": ["system", "self", "others"]
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      ImageId:
        Type: String
        AssociationProperty: ALIYUN::ECS::Image::ImageId
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
          SupportedImageOwnerAlias:
            - system
            - self
            - others
  • 示例说明

    示例中通过指定参数ImageId的AssociationProperty属性为ALIYUN::ECS::Image::ImageId,AssociationPropertyMetadata属性为RegionId、SupportedImageOwnerAlias,获取当前可用区下的ECS镜像ID。

ALIYUN::ECS::ResourceGroup::ResourceGroupId

资源组。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "ResourceGroupId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::ResourceGroup::ResourceGroupId"
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      ResourceGroupId:
        Type: String
        AssociationProperty: ALIYUN::ECS::ResourceGroup::ResourceGroupId
  • 示例说明

    示例中通过指定参数ResourceGroupId的AssociationProperty属性为ALIYUN::ECS::ResourceGroup::ResourceGroupId。

ALIYUN::ECS::LaunchTemplate::LaunchTemplateId

实例启动模板ID。

RegionId:地域ID(默认为资源栈所属地域)。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "LaunchTemplateId":{
          "AssociationProperty":"ALIYUN::ECS::LaunchTemplate::LaunchTemplateId",
          "Type":"String",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      LaunchTemplateId:
        AssociationProperty: ALIYUN::ECS::LaunchTemplate::LaunchTemplateId
        Type: String
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数LaunchTemplateId的AssociationProperty属性为ALIYUN::ECS::LaunchTemplate::LaunchTemplateId ,AssociationPropertyMetadata属性为RegionId,获取当前可用区下ECS的启动模板。

ALIYUN::ECS::LaunchTemplate::LaunchTemplateVersion

实例启动模板版本。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • LaunchTemplateId:实例启动模板ID。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "LaunchTemplateId": {
          "AssociationProperty": "ALIYUN::ECS::LaunchTemplate::LaunchTemplateId",
          "Type": "String",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        },
        "LaunchTemplateVersion": {
          "AssociationProperty": "ALIYUN::ECS::LaunchTemplate::LaunchTemplateVersion",
          "Type": "String",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}",
            "LaunchTemplateId": "${LaunchTemplateId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      LaunchTemplateId:
        AssociationProperty: ALIYUN::ECS::LaunchTemplate::LaunchTemplateId
        Type: String
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
      LaunchTemplateVersion:
        AssociationProperty: ALIYUN::ECS::LaunchTemplate::LaunchTemplateVersion
        Type: String
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
          LaunchTemplateId: ${LaunchTemplateId}
  • 示例说明

    示例中通过指定参数LaunchTemplateVersion的AssociationProperty属性为ALIYUN::ECS::LaunchTemplate::LaunchTemplateVersion ,AssociationPropertyMetadata属性为RegionId、LaunchTemplateId,获取所选ECS的启动模板的版本信息。

ALIYUN::RDS::Instance::InstanceType

RDS实例规格。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • ZoneId:可用区ID。

  • InstanceChargeType:实例付费类型。

  • Category:实例系列。

  • Engine:数据库类型。

  • EngineVersion:数据库版本号。

  • DBInstanceClass:实例规格。

  • OrderType:订单类型。

  • DBInstanceStorageType:实例存储类型。

  • DispenseMode:分配模式。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "ZoneId": {
          "Type": "String",
          "AssociationProperty": "ZoneId"
        },
        "InstanceType": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::RDS::Instance::InstanceType",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}",
            "ZoneId": "${ZoneId}",
            "Engine": "MySQL"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      ZoneId:
        Type: String
        AssociationProperty: ZoneId
      InstanceType:
        Type: String
        AssociationProperty: ALIYUN::RDS::Instance::InstanceType
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
          ZoneId: ${ZoneId}
          Engine: MySQL
  • 示例说明

    示例中通过指定参数InstanceType的AssociationProperty属性为ALIYUN::RDS::Instance::InstanceType,AssociationPropertyMetadata属性为RegionId、Engine、ZoneId,获取所选可用区下的所属数据库类型的RDS实例规格。

ALIYUN::SLB::Instance::InstanceType

SLB实例规格。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • ZoneId:可用区ID。

  • InstanceChargeType:实例付费类型。

  • SpotStrategy:按量付费实例的竞价策略。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "ZoneId": {
          "Type": "String",
          "AssociationProperty": "ZoneId"
        },
        "InstanceType": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::SLB::Instance::InstanceType",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}",
            "ZoneId": "${ZoneId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      ZoneId:
        Type: String
        AssociationProperty: ZoneId
      InstanceType:
        Type: String
        AssociationProperty: ALIYUN::SLB::Instance::InstanceType
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
          ZoneId: ${ZoneId}
  • 示例说明

    示例中通过指定参数InstanceType的AssociationProperty属性为ALIYUN::SLB::Instance::InstanceType,AssociationPropertyMetadata属性为RegionId、ZoneId,获取所选可用区下的SLB实例规格。

ALIYUN::SLB::Certificate

SLB证书。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "ZoneId": {
          "Type": "String",
          "AssociationProperty": "ZoneId"
        },
        "Certificate": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::SLB::Certificate",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}",
            "ZoneId": "${ZoneId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      ZoneId:
        Type: String
        AssociationProperty: ZoneId
      Certificate:
        Type: String
        AssociationProperty: ALIYUN::SLB::Certificate
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
          ZoneId: ${ZoneId}
  • 示例说明

    示例中通过指定参数Certificate的AssociationProperty属性为ALIYUN::SLB::Certificate,AssociationPropertyMetadata属性为RegionId、ZoneId,获取所选可用区下的SLB证书。

ALIYUN::SLB::LoadBalancer::LoadBalancerId

SLB实例ID。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • VpcId:专有网络ID。

  • VSwitchId:交换机ID。

  • NetworkType:NAT网关的网络类型。

  • InstanceChargeType:实例付费类型。

  • AddressType:网络类型。

  • MasterZoneId:负载均衡实例的主可用区ID。

  • SlaveZoneId:负载均衡实例的备可用区ID。

  • PayType:负载均衡实例付费模式。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "SlbInstanceId":{
          "AssociationProperty":"ALIYUN::SLB::LoadBalancer::LoadBalancerId",
          "Type":"String",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      SlbInstanceId:
        AssociationProperty: ALIYUN::SLB::LoadBalancer::LoadBalancerId
        Type: String
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数SlbInstanceId的AssociationProperty属性为ALIYUN::SLB::LoadBalancer::LoadBalancerId,AssociationPropertyMetadata属性为RegionId,获取当前地域下的SLB实例ID。

ALIYUN::SLB::ACL::ACLId

SLB访问控制ID。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • AddressIPVersion:IP地址类型。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "SlbACLId":{
          "AssociationProperty":"ALIYUN::SLB::ACL::ACLId",
          "Type":"String",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}",
            "AddressIPVersion":"${AddressIPVersion}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      SlbACLId:
        AssociationProperty: ALIYUN::SLB::ACL::ACLId
        Type: String
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
          AddressIPVersion: ${AddressIPVersion}
  • 示例说明

    示例中通过指定参数SlbACLId的AssociationProperty属性为ALIYUN::SLB::ACL::ACLId,AssociationPropertyMetadata属性为RegionId,获取当前地域下的SLB访问控制。

ALIYUN::OOS::Template::TemplateName

OOS模板。

RegionId:地域ID(默认为资源栈所属地域)。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "TemplateName": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::OOS::Template::TemplateName",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      TemplateName:
        Type: String
        AssociationProperty: ALIYUN::OOS::Template::TemplateName
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数TemplateName的AssociationProperty属性为ALIYUN::OOS::Template::TemplateName,AssociationPropertyMetadata属性为RegionId,获取当前地域下的OOS模板信息。

ALIYUN::OOS::Template::TemplateVersion

OOS模板版本。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • TemplateName:模板名称。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "TemplateName": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::OOS::Template::TemplateName",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        },
        "TemplateVersion": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::OOS::Template::TemplateVersion",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}",
            "TemplateName": "${TemplateName}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      TemplateName:
        Type: String
        AssociationProperty: ALIYUN::OOS::Template::TemplateName
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
      TemplateVersion:
        Type: String
        AssociationProperty: ALIYUN::OOS::Template::TemplateVersion
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
          TemplateName: ${TemplateName}
  • 示例说明

    示例中通过指定参数TemplateVersion的AssociationProperty属性为ALIYUN::OOS::Template::TemplateVersion,AssociationPropertyMetadata属性为RegionId、TemplateName,获取当前地域下的OOS模板版本信息。

ALIYUN::OOS::Parameter::Value

OOS普通参数。

RegionId:地域ID(默认为资源栈所属地域)。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "ParameterValue": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::OOS::Parameter::Value",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      ParameterValue:
        Type: String
        AssociationProperty: ALIYUN::OOS::Parameter::Value
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数ParameterValue的AssociationProperty属性为ALIYUN::OOS::Parameter::Value,AssociationPropertyMetadata属性为RegionId,获取当前地域下的OOS普通参数信息。

ALIYUN::OOS::SecretParameter::Value

OOS加密参数。

RegionId:地域ID(默认为资源栈所属地域)。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "SecretParameter": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::OOS::SecretParameter::Value",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      SecretParameter:
        Type: String
        AssociationProperty: ALIYUN::OOS::SecretParameter::Value
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数SecretParameter的AssociationProperty属性为ALIYUN::OOS::SecretParameter::Value,AssociationPropertyMetadata属性为RegionId,获取当前地域下的OOS加密参数信息。

ALIYUN::OOS::Package::PackageName

OOS软件包名称。

RegionId:地域ID(默认为资源栈所属地域)。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "PackageName": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::OOS::Package::PackageName",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      PackageName:
        Type: String
        AssociationProperty: ALIYUN::OOS::Package::PackageName
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数PackageName的AssociationProperty属性为ALIYUN::OOS::Package::PackageName,AssociationPropertyMetadata属性为RegionId,获取当前地域下的OOS软件包信息。

ALIYUN::OOS::Package::PackageVersion

OOS软件包版本。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • TemplateName:模板名称。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "PackageName": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::OOS::Package::PackageName",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        },
        "PackageVersion": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::OOS::Package::PackageVersion",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}",
            "TemplateName": "${PackageName}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      PackageName:
        Type: String
        AssociationProperty: ALIYUN::OOS::Package::PackageName
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
      PackageVersion:
        Type: String
        AssociationProperty: ALIYUN::OOS::Package::PackageVersion
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
          TemplateName: ${PackageName}
  • 示例说明

    示例中通过指定参数PackageVersion的AssociationProperty属性为ALIYUN::OOS::Package::PackageVersion,AssociationPropertyMetadata属性为RegionId、TemplateName,获取当前地域下的OOS软件包版本信息。

ALIYUN::OOS::Command::CommandContent

OOS执行脚本。

CommandType:命令类型。

取值:

  • RunBatScript

  • RunPowerShellScript

  • RunShellScript

  • RunPythonScript

  • RunPerlScript

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "CommandContent": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::OOS::Command::CommandContent",
          "AssociationPropertyMetadata": {
            "CommandType": "RunPythonScript"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      CommandContent:
        Type: String
        AssociationProperty: ALIYUN::OOS::Command::CommandContent
        AssociationPropertyMetadata:
          CommandType: RunPythonScript
  • 示例说明

    示例中通过指定参数CommandContent的AssociationProperty属性为ALIYUN::OOS::Command::CommandContent,AssociationPropertyMetadata属性为CommandType,实现OOS执行脚本。

ALIYUN::OOS::File::FileUrl

上传文件的URL。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • FileType:导出格式。

    取值:local、https、gitub、oss。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "FileUrl": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::OOS::File::FileUrl",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      FileUrl:
        Type: String
        AssociationProperty: ALIYUN::OOS::File::FileUrl
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数FileUrl的AssociationProperty属性为ALIYUN::OOS::File::FileUrl,实现上传文件至OSS。

ALIYUN::OSS::Bucket::BucketName

OSS存储空间名称。

RegionId:地域ID(默认为资源栈所属地域)。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "BucketName": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::OSS::Bucket::BucketName",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      BucketName:
        Type: String
        AssociationProperty: ALIYUN::OSS::Bucket::BucketName
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数BucketName的AssociationProperty属性为ALIYUN::OSS::Bucket::BucketName,AssociationPropertyMetadata属性为RegionId,获取当前地域下的OSS存储空间。

ALIYUN::OSS::Object::ObjectName

OSS对象名称。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • BucketName:存储空间名称。

  • ValueType:返回地址类型。

    • 默认值为OSS Url,即返回完整的地址,例如:oss://beijing-test-delete/test.xml

    • 设置为任何其他值,则只返回object的名称,例如test.xml

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "BucketName": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::OSS::Bucket::BucketName",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        },
        "ObjectName": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::OSS::Object::ObjectName",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}",
            "BucketName": "${BucketName}",
            "ValueType": "${BucketName}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      BucketName:
        Type: String
        AssociationProperty: ALIYUN::OSS::Bucket::BucketName
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
      ObjectName:
        Type: String
        AssociationProperty: ALIYUN::OSS::Object::ObjectName
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
          BucketName: ${BucketName}
          ValueType: ${BucketName}
  • 示例说明

    示例中通过指定参数ObjectName的AssociationProperty属性为ALIYUN::OSS::Object::ObjectName,AssociationPropertyMetadata属性为RegionId、BucketName,获取当前地域下的OSS对象。

ALIYUN::OOS::Component::TimerTrigger

OOS时间触发组件。

RegionId:地域ID(默认为资源栈所属地域)。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "TimerTrigger": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::OOS::Component::TimerTrigger",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      TimerTrigger:
        Type: String
        AssociationProperty: ALIYUN::OOS::Component::TimerTrigger
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数TimerTrigger的AssociationProperty属性为ALIYUN::OOS::Component::TimerTrigger,AssociationPropertyMetadata属性为RegionId,实现配置OOS时间触发组件。

ALIYUN::VPC::VirtualBorderRouter::RouteTableId

边界路由器ID。

RegionId:地域ID(默认为资源栈所属地域)。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "RouteTableId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::VPC::VirtualBorderRouter::RouteTableId",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      RouteTableId:
        Type: String
        AssociationProperty: ALIYUN::VPC::VirtualBorderRouter::RouteTableId
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数RouteTableId的AssociationProperty属性为ALIYUN::VPC::VirtualBorderRouter::RouteTableId,AssociationPropertyMetadata属性为RegionId,实现获取当前地域下VBR实例ID。

ALIYUN::VPC::NatGateway::NatGatewayId

NAT网关ID。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • ZoneId:可用区ID。

  • VpcId:专有网络ID。

  • InstanceChargeType:实例付费类型。

  • NatType:NAT网关类型。

  • NetworkType:NAT网关的网络类型。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "ZoneId": {
          "Type": "String",
          "AssociationProperty": "ZoneId",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        },
        "VpcId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::VPC::VPCId",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        },
        "NatGateway": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::VPC::NatGateway::NatGatewayId",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}",
            "ZoneId": "${ZoneId}",
            "VpcId": "${VpcId}",
            "InstanceChargeType": "PostPaid",
            "NatType": "Enhanced",
            "NetworkType": "intranet"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      ZoneId:
        Type: String
        AssociationProperty: ZoneId
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
      VpcId:
        Type: String
        AssociationProperty: ALIYUN::ECS::VPC::VPCId
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
      NatGateway:
        Type: String
        AssociationProperty: ALIYUN::VPC::NatGateway::NatGatewayId
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
          ZoneId: ${ZoneId}
          VpcId: ${VpcId}
          InstanceChargeType: PostPaid
          NatType: Enhanced
          NetworkType: intranet
  • 示例说明

    示例中通过指定参数NatGateway的AssociationProperty属性为ALIYUN::VPC::NatGateway::NatGatewayId,AssociationPropertyMetadata属性为RegionId、ZoneId、VpcId、InstanceChargeType、NatType和NetworkType,获取当前地域下符合过滤条件的NAT网关ID。

ALIYUN::VPC::VSwitch::CidrBlock

创建vSwitch的CIDR。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • VpcId:专有网络ID。

  • VpcCidrBlock:VPC网段。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "RegionId"
        },
        "VpcId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::VPC::VPCId",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        },
        "CIDR": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::VPC::VSwitch::CidrBlock",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}",
            "VpcId": "${VpcId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: RegionId
      VpcId:
        Type: String
        AssociationProperty: ALIYUN::ECS::VPC::VPCId
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
      CIDR:
        Type: String
        AssociationProperty: ALIYUN::VPC::VSwitch::CidrBlock
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
          VpcId: ${VpcId}
  • 示例说明

    示例中通过指定参数CIDR的AssociationProperty属性为ALIYUN::VPC::VSwitch::CidrBlock,AssociationPropertyMetadata为RegionId、VpcId,实现配置vSwitch的CIDR信息。

ALIYUN::VPC::VPC::CidrBlock

新建VPC的CIDR。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "CIDR": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::VPC::VPC::CidrBlock"
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      CIDR:
        Type: String
        AssociationProperty: ALIYUN::VPC::VPC::CidrBlock
  • 示例说明

    示例中通过指定参数CIDR的AssociationProperty属性为ALIYUN::VPC::VPC::CidrBlock,实现配置VPC的CIDR信息。

ALIYUN::ESS::ScalingConfiguration::ScalingConfigurationId

弹性伸缩配置ID。

RegionId:地域ID(默认为资源栈所属地域)。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "ScalingConfigurationId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ESS::ScalingConfiguration::ScalingConfigurationId",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      ScalingConfigurationId:
        Type: String
        AssociationProperty: ALIYUN::ESS::ScalingConfiguration::ScalingConfigurationId
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数ScalingConfigurationId的AssociationProperty属性为ALIYUN::ESS::ScalingConfiguration::ScalingConfigurationId,实现获取弹性伸缩配置ID信息。

ALIYUN::ESS::AutoScalingGroup::AutoScalingGroupId

ESS伸缩组ID。

RegionId:地域ID(默认为资源栈所属地域)。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "AutoScalingGroupId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ESS::AutoScalingGroup::AutoScalingGroupId",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      AutoScalingGroupId:
        Type: String
        AssociationProperty: ALIYUN::ESS::AutoScalingGroup::AutoScalingGroupId
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数AutoScalingGroupId的AssociationProperty属性为ALIYUN::ESS::AutoScalingGroup::AutoScalingGroupId,实现获取弹性伸缩组ID信息。

ALIYUN::RAM::User

RAM用户。

RegionId:地域ID(默认为资源栈所属地域)。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "User": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::RAM::User",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      User:
        Type: String
        AssociationProperty: ALIYUN::RAM::User
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数User的AssociationProperty属性为ALIYUN::RAM::User,AssociationPropertyMetadata为RegionId,实现获取当前地域下的RAM用户。

ALIYUN::RAM::Role

RAM角色。

RegionId:地域ID(默认为资源栈所属地域)。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "Role": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::RAM::Role",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      Role:
        Type: String
        AssociationProperty: ALIYUN::RAM::Role
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数Role的AssociationProperty属性为ALIYUN::RAM::Role,AssociationPropertyMetadata属性为RegionId,实现获取当前地域下的RAM角色。

ALIYUN::CAS::Certificate::CertificateId

SLB实例的证书。

RegionId:地域ID(默认为资源栈所属地域)。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "Certificate": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::CAS::Certificate::CertificateId",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      Certificate:
        Type: String
        AssociationProperty: ALIYUN::CAS::Certificate::CertificateId
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数Certificate的AssociationProperty属性为ALIYUN::CAS::Certificate::CertificateId,AssociationPropertyMetadata属性为RegionId,获取当前地域下SLB服务证书。

ALIYUN::Elasticsearch::Instance::InstanceType

Elasticsearch实例规格。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "Elasticsearch": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::Elasticsearch::Instance::InstanceType"
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      Elasticsearch:
        Type: String
        AssociationProperty: ALIYUN::Elasticsearch::Instance::InstanceType
  • 示例说明

    示例中通过指定参数Elasticsearch的AssociationProperty属性为ALIYUN::Elasticsearch::Instance::InstanceType,获取Elasticsearch 实例规格。

ALIYUN::InfluxDB::Instance::InstanceType

InfluxDB实例规格。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • ZoneId:可用区ID。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "ZoneId": {
          "Type": "String",
          "AssociationProperty": "ZoneId"
        },
        "InfluxDB": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::InfluxDB::Instance::InstanceType",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}",
            "ZoneId": "${ZoneId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      ZoneId:
        Type: String
        AssociationProperty: ZoneId
      InfluxDB:
        Type: String
        AssociationProperty: ALIYUN::InfluxDB::Instance::InstanceType
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
          ZoneId: ${ZoneId}
  • 示例说明

    示例中通过指定参数InfluxDB的AssociationProperty属性为ALIYUN::InfluxDB::Instance::InstanceType,获取InfluxDB 实例规格。

ALIYUN::Redis::Instance::InstanceType

Redis实例规格。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • ZoneId:可用区ID。

  • InstanceChargeType:实例付费类型。

  • Engine:数据库类型。

  • ProductType:产品类型。

  • OrderType:订单类型。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "ZoneId": {
          "Type": "String",
          "AssociationProperty": "ZoneId"
        },
        "Redis": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::Redis::Instance::InstanceType",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}",
            "ZoneId": "${ZoneId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      ZoneId:
        Type: String
        AssociationProperty: ZoneId
      Redis:
        Type: String
        AssociationProperty: ALIYUN::Redis::Instance::InstanceType
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
          ZoneId: ${ZoneId}
  • 示例说明

    示例中通过指定参数Redis的AssociationProperty属性为ALIYUN::Redis::Instance::InstanceType,获取Redis实例规格。

ALIYUN::EHPC::FileSystem::FileSystemId

文件系统ID。

RegionId:地域ID(默认为资源栈所属地域)。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "FileSystemId":{
          "AssociationProperty":"ALIYUN::EHPC::FileSystem::FileSystemId",
          "Type":"String",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      FileSystemId:
        AssociationProperty: ALIYUN::EHPC::FileSystem::FileSystemId
        Type: String
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数FileSystemId的AssociationProperty属性为ALIYUN::EHPC::FileSystem::FileSystemId,获取EHPC文件系统ID。

ALIYUN::EHPC::FileSystem::MountTargetDomain

挂载点。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • VolumeId:阿里云NAS实例ID。

  • VpcId:专有网络ID。

  • VSwitchId:交换机ID。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "MountTargetDomain":{
          "AssociationProperty":"ALIYUN::EHPC::FileSystem::MountTargetDomain",
          "Type":"String",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      MountTargetDomain:
        AssociationProperty: ALIYUN::EHPC::FileSystem::MountTargetDomain
        Type: String
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数MountTargetDomain的AssociationProperty属性为ALIYUN::EHPC::FileSystem::MountTargetDomain,获取EHPC文件挂载点列表。

ALIYUN::EHPC::Cluster::ClusterId

集群选择 。

RegionId:地域ID(默认为资源栈所属地域)。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "ClusterId":{
          "AssociationProperty":"ALIYUN::EHPC::Cluster::ClusterId",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          },
          "Type":"String"
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      ClusterId:
        AssociationProperty: ALIYUN::EHPC::Cluster::ClusterId
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
        Type: String
  • 示例说明

    示例中通过指定参数ClusterId的AssociationProperty属性为ALIYUN::EHPC::Cluster::ClusterId,获取EHPC集群ID。

ALIYUN::ALB::Instance::InstanceId

ALB实例。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • VpcId:专有网络ID。

  • AddressType:网络类型。

  • ZoneId:可用区ID。

  • PayType:负载均衡实例付费模式。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "AlbInstanceId":{
          "AssociationProperty":"ALIYUN::ALB::Instance::InstanceId",
          "Type":"String",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      AlbInstanceId:
        AssociationProperty: ALIYUN::ALB::Instance::InstanceId
        Type: String
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数AlbInstanceId的AssociationProperty属性为ALIYUN::ALB::Instance::InstanceId,获取ALB实例ID。

ALIYUN::ALB::ACL::ACLId

ALB访问控制。

RegionId:地域ID(默认为资源栈所属地域)。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "RegionId"
        },
        "AlbACLId":{
          "AssociationProperty":"ALIYUN::ALB::ACL::ACLId",
          "AssociationPropertyMetadata": {
             "RegionId": "${RegionId}"
          },
          "Type":"String"
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: RegionId
      AlbACLId:
        AssociationProperty: ALIYUN::ALB::ACL::ACLId
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
        Type: String
  • 示例说明

    示例中通过指定参数AlbACLId的AssociationProperty属性为ALIYUN::ALB::ACL::ACLId,获取ALB访问控制ID。

ALIYUN::ALB::LoadBalancer::LoadBalancerId

ALB实例ID。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • VpcId:专有网络ID。

  • AddressType:网络类型。

  • ZoneId:可用区ID。

  • PayType:负载均衡实例付费模式。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "AlbLoadBalancerId":{
          "AssociationProperty":"ALIYUN::ALB::LoadBalancer::LoadBalancerId",
          "Type":"String",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      AlbLoadBalancerId:
        AssociationProperty: ALIYUN::ALB::LoadBalancer::LoadBalancerId
        Type: String
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数AlbLoadBalancerId的AssociationProperty属性为ALIYUN::ALB::LoadBalancer::LoadBalancerId,获取ALB实例ID。

ALIYUN::ResourceManager::Folder

资源目录。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "ResourceFolder": {
          "AssociationProperty": "ALIYUN::ResourceManager::Folder",
          "Type": "Json",
          "Description": {
            "zh-cn": "选择资源目录",
            "en": "ResourceFolder"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      ResourceFolder:
        AssociationProperty: ALIYUN::ResourceManager::Folder
        Type: Json
        Description:
          zh-cn: 选择资源目录
          en: ResourceFolder
  • 示例说明

    示例中通过指定参数ResourceFolder的AssociationProperty属性为ALIYUN::ResourceManager::Folder,获取当前账号下的资源目录。

ALIYUN::ResourceManager::Account

资源账号。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "ResourceAccount": {
          "AssociationProperty": "ALIYUN::ResourceManager::Account",
          "Type": "Json",
          "Description": {
            "zh-cn": "选择资源账号",
            "en": "ResourceAccount"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      ResourceAccount:
        AssociationProperty: ALIYUN::ResourceManager::Account
        Type: Json
        Description:
          zh-cn: 选择资源账号
          en: ResourceAccount
  • 示例说明

    示例中通过指定参数ResourceAccount的AssociationProperty属性为ALIYUN::ResourceManager::Account,获取资源目录中的账号。

ALIYUN::CMS::Alarm::Rule

阈值报警规则。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "Rule": {
          "AssociationProperty": "ALIYUN::CMS::Alarm::Rule",
          "Type": "String",
          "Description": {
            "zh-cn": "选择阈值报警规则",
            "en": "AlarmRule"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      Rule:
        AssociationProperty: ALIYUN::CMS::Alarm::Rule
        Type: String
        Description:
          zh-cn: 选择阈值报警规则
          en: AlarmRule
  • 示例说明

    示例中通过指定参数Rule的AssociationProperty属性为ALIYUN::CMS::Alarm::Rule,获取阈值报警规则。

ALIYUN::CMS::Alarm::SilenceTime

报警沉默周期。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "SilenceTime": {
          "AssociationProperty": "ALIYUN::CMS::Alarm::SilenceTime",
          "Type": "String",
          "Description": {
            "zh-cn": "报警沉默周期",
            "en": "SilenceTime"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      SilenceTime:
        AssociationProperty: ALIYUN::CMS::Alarm::SilenceTime
        Type: String
        Description:
          zh-cn: 报警沉默周期
          en: SilenceTime
  • 示例说明

    示例中通过指定参数SilenceTime的AssociationProperty属性为ALIYUN::CMS::Alarm::SilenceTime,获取报警沉默周期。

ALIYUN::CMS::Alarm::TriggerResources

报警资源触发器。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "TriggerResources": {
          "AssociationProperty": "ALIYUN::CMS::Alarm::TriggerResources",
          "Type": "String",
          "Description": {
            "zh-cn": "选择报警资源触发器",
            "en": "TriggerResources"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      TriggerResources:
        AssociationProperty: ALIYUN::CMS::Alarm::TriggerResources
        Type: String
        Description:
          zh-cn: 选择报警资源触发器
          en: TriggerResources
  • 示例说明

    示例中通过指定参数TriggerResources的AssociationProperty属性为ALIYUN::CMS::Alarm::TriggerResources,获取报警资源触发器。

ALIYUN::CMS::Event::EventFilterRule

事件报警规则。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "EventRule": {
          "AssociationProperty": "ALIYUN::CMS::Event::EventFilterRule",
          "Type": "String",
          "Description": {
            "zh-cn": "选择事件报警规则",
            "en": "EventRule"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      EventRule:
        AssociationProperty: ALIYUN::CMS::Event::EventFilterRule
        Type: String
        Description:
          zh-cn: 选择事件报警规则
          en: EventRule
  • 示例说明

    示例中通过指定参数EventRule的AssociationProperty属性为ALIYUN::CMS::Event::EventFilterRule,获取事件报警规则。

ALIYUN::CMS::Event::EventLevel

事件报警级别。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "EventLevel": {
          "AssociationProperty": "ALIYUN::CMS::Event::EventLevel",
          "Type": "String",
          "Description": {
            "zh-cn": "选择事件报警级别",
            "en": "EventLevel"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      EventLevel:
        AssociationProperty: ALIYUN::CMS::Event::EventLevel
        Type: String
        Description:
          zh-cn: 选择事件报警级别
          en: EventLevel
  • 示例说明

    示例中通过指定参数EventLevel的AssociationProperty属性为ALIYUN::CMS::Event::EventLevel,获取事件报警级别。

ALIYUN::CMS::Event::EventName

事件报警名称。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "EventName": {
          "AssociationProperty": "ALIYUN::CMS::Event::EventName",
          "Type": "String",
          "Description": {
            "zh-cn": "选择事件报警名称",
            "en": "EventName"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      EventName:
        AssociationProperty: ALIYUN::CMS::Event::EventName
        Type: String
        Description:
          zh-cn: 选择事件报警名称
          en: EventName
  • 示例说明

    示例中通过指定参数EventName的AssociationProperty属性为ALIYUN::CMS::Event::EventName,获取事件报警名称。

ALIYUN::CMS::Product::ProductType

事件支持的云服务。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "ProductType": {
          "AssociationProperty": "ALIYUN::CMS::Product::ProductType",
          "Type": "String",
          "Description": {
            "zh-cn": "选择事件报警名称",
            "en": "ProductType"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      ProductType:
        AssociationProperty: ALIYUN::CMS::Product::ProductType
        Type: String
        Description:
          zh-cn: 选择事件报警名称
          en: ProductType
  • 示例说明

    示例中通过指定参数ProductType的AssociationProperty属性为ALIYUN::CMS::Product::ProductType,获取事件支持的云服务。

ALIYUN::CS::Cluster::ClusterId

容器集群ID。

  • RegionId:地域ID(默认为资源栈所属地域)。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "ClusterId":{
          "AssociationProperty":"ALIYUN::CS::Cluster::ClusterId",
          "Type":"String",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      ClusterId:
        AssociationProperty: ALIYUN::CS::Cluster::ClusterId
        Type: String
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数ClusterId的AssociationProperty属性为ALIYUN::CS::Cluster::ClusterId,获取容器集群ID。

ALIYUN::CS::Cluster::ClusterNodePool

容器集群内的节点池。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • ClusterId:容器集群ID。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "ClusterId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::CS::Cluster::ClusterId"
        },
        "ClusterNodePool":{
          "AssociationProperty":"ALIYUN::CS::Cluster::ClusterId",
          "Type":"String",
          "AssociationPropertyMetadata": {
            "ClusterId": "${ClusterId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      ClusterId:
        Type: String
        AssociationProperty: ALIYUN::CS::Cluster::ClusterId
      ClusterNodePool:
        AssociationProperty: ALIYUN::CS::Cluster::ClusterId
        Type: String
        AssociationPropertyMetadata:
          ClusterId: ${ClusterId}
  • 示例说明

    示例中通过指定参数ClusterNodePool的AssociationProperty属性为ALIYUN::CS::Cluster::ClusterNodePool,获取容器集群内的节点池。

ALIYUN::ComputeNest::Service::ServiceId

计算巢服务ID。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • InUsed:是否被使用。

  • IsVendor:是否有服务商。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "ServiceId":{
          "AssociationProperty":"ALIYUN::ComputeNest::Service::ServiceId",
          "Type":"String",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      ServiceId:
        AssociationProperty: ALIYUN::ComputeNest::Service::ServiceId
        Type: String
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数ServiceId的AssociationProperty属性为ALIYUN::ComputeNest::Service::ServiceId,获取计算巢服务ID。

ALIYUN::ComputeNest::ServiceInstance::ServiceInstanceId

计算巢服务实例ID。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • ServiceType:服务类型。

  • DeployType:部署类型。

  • Status:服务状态。

  • ServiceId:服务ID。

  • Version:服务版本。

  • IsVendor:是否有服务商。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "ServiceId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ComputeNest::Service::ServiceId"
        },
        "ServiceInstanceId":{
          "AssociationProperty":"ALIYUN::ComputeNest::ServiceInstance::ServiceInstanceId",
          "Type":"String",
          "AssociationPropertyMetadata": {
            "ServiceId": "${ServiceId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      ServiceId:
        Type: String
        AssociationProperty: ALIYUN::ComputeNest::Service::ServiceId
      ServiceInstanceId:
        AssociationProperty: ALIYUN::ComputeNest::ServiceInstance::ServiceInstanceId
        Type: String
        AssociationPropertyMetadata:
          ServiceId: ${ServiceId}
  • 示例说明

    示例中通过指定参数ServiceInstanceId的AssociationProperty属性为ALIYUN::ComputeNest::ServiceInstance::ServiceInstanceId,获取计算巢服务实例ID。

ALIYUN::ComputeNestSupplier::Service::ServiceVersion

计算巢服务版本。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • ServiceId:服务ID。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "ServiceId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ComputeNest::Service::ServiceId"
        },
        "ServiceVersion":{
          "AssociationProperty":"ALIYUN::ComputeNestSupplier::Service::ServiceVersion",
          "Type":"String",
          "AssociationPropertyMetadata": {
            "ServiceId": "${ServiceId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      ServiceId:
        Type: String
        AssociationProperty: ALIYUN::ComputeNest::Service::ServiceId
      ServiceVersion:
        AssociationProperty: ALIYUN::ComputeNestSupplier::Service::ServiceVersion
        Type: String
        AssociationPropertyMetadata:
          ServiceId: ${ServiceId}
  • 示例说明

    示例中通过指定参数ServiceVersion的AssociationProperty属性为ALIYUN::ComputeNestSupplier::Service::ServiceVersion,获取计算巢服务版本。

ALIYUN::MongoDB::Instance::InstanceType

MongoDB实例规格

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "InstanceType":{
          "AssociationProperty":"ALIYUN::MongoDB::Instance::InstanceType",
          "Type":"String"
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      InstanceType:
        AssociationProperty: ALIYUN::MongoDB::Instance::InstanceType
        Type: String
  • 示例说明

    示例中通过指定参数InstanceType的AssociationProperty属性为ALIYUN::MongoDB::Instance::InstanceType,获取MongoDB实例规格。

ALIYUN::NLB::LoadBalancer::LoadBalancerId

网络型负载均衡实例ID。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • VpcIds:专有网络ID列表。

  • AddressType:网络类型。

  • ZoneId:可用区ID。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "InstanceId":{
          "AssociationProperty":"ALIYUN::NLB::LoadBalancer::LoadBalancerId",
          "Type":"String",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      InstanceId:
        AssociationProperty: ALIYUN::NLB::LoadBalancer::LoadBalancerId
        Type: String
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数InstanceId的AssociationProperty属性为ALIYUN::NLB::LoadBalancer::LoadBalancerId,获取网络型负载均衡实例ID。

ALIYUN::NLB::Zone::ZoneId

网络型负载均衡可用区

  • RegionId:地域ID(默认为资源栈所属地域)。

  • ShowRandom:展示随机分配选项。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "ZoneId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::NLB::Zone::ZoneId",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      ZoneId:
        Type: String
        AssociationProperty: ALIYUN::NLB::Zone::ZoneId
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数ZoneId的AssociationProperty属性为ALIYUN::NLB::Zone::ZoneId,AssociationPropertyMetadata属性为RegionId,获取当前可用地域下网络型负载均衡的可用区。

ALIYUN::OSS::Bucket::Object

OSS存储对象。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • ObjectType:Object的存储类型。

  • ValueType:Object值的类型。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "BucketObject": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::NLB::Zone::ZoneId",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      BucketObject:
        Type: String
        AssociationProperty: ALIYUN::NLB::Zone::ZoneId
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数ZoneId的AssociationProperty属性为ALIYUN::OSS::Bucket::Object,AssociationPropertyMetadata属性为RegionId,获取当前可用地域下OSS存储对象。

ALIYUN::POLARDB::DBCluster::DBClusterId

PolarDB实例ID。

  • RegionId:地域ID(默认为资源栈所属地域)。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "DBClusterId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::POLARDB::DBCluster::DBClusterId",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      DBClusterId:
        Type: String
        AssociationProperty: ALIYUN::POLARDB::DBCluster::DBClusterId
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数ZoneId的AssociationProperty属性为ALIYUN::POLARDB::DBCluster::DBClusterId,AssociationPropertyMetadata属性为RegionId,获取当前可用地域下PolarDB实例ID。

ALIYUN::POLARDB::DBCluster::DBNodeClass

查询PolarDB集群可售卖资源。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • ZoneId:可用区ID。

  • PayType:付费类型。

    • Postpaid:按量付费(也称后付费或按小时付费)(默认值)。

    • Prepaid:包年包月(也称预付费)。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "ZoneId": {
          "Type": "String",
          "AssociationProperty": "ZoneId",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        },
        "DBNodeClass": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::POLARDB::DBCluster::DBNodeClass",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}",
            "ZoneId": "${ZoneId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      ZoneId:
        Type: String
        AssociationProperty: ZoneId
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
      DBNodeClass:
        Type: String
        AssociationProperty: ALIYUN::POLARDB::DBCluster::DBNodeClass
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
          ZoneId: ${ZoneId}

ALIYUN::RDS::Instance::AccountPassword

RDS数据库账号密码。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "AccountPassword": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::RDS::Instance::AccountPassword"
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      AccountPassword:
        Type: String
        AssociationProperty: ALIYUN::RDS::Instance::AccountPassword
  • 示例说明

    示例中通过指定参数AccountPassword的AssociationProperty属性为ALIYUN::RDS::Instance::AccountPassword,获取RDS数据库账号密码。

ALIYUN::Redis::Instance::InstanceId

Redis实例ID。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • InstanceType:实例类型。

  • ChargeType:付费类型。

  • EditionType:实例类型。

  • InstanceClass:实例规格。

  • NetworkType:网络类型。

  • InstanceStatus:实例状态。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "InstanceId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::Redis::Instance::InstanceId",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      InstanceId:
        Type: String
        AssociationProperty: ALIYUN::Redis::Instance::InstanceId
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数InstanceId的AssociationProperty属性为ALIYUN::Redis::Instance::InstanceId,AssociationPropertyMetadata属性为RegionId,获取当前可用地域下Redis实例ID。

ALIYUN::ServiceCatalog::LaunchOption::PortfolioId

服务目录产品组合ID。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • ProductId:产品ID。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "PortfolioId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ServiceCatalog::LaunchOption::PortfolioId",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      PortfolioId:
        Type: String
        AssociationProperty: ALIYUN::ServiceCatalog::LaunchOption::PortfolioId
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数PortfolioId的AssociationProperty属性为ALIYUN::ServiceCatalog::LaunchOption::PortfolioId,AssociationPropertyMetadata属性为RegionId,获取当前可用地域下服务目录产品组合ID。

ALIYUN::ServiceCatalog::ProductVersion::ProductVersionId

产品版本ID。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • ProductId:产品ID。

  • Active:是否启用。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "RegionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ECS::RegionId"
        },
        "ProductVersionId": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::ServiceCatalog::ProductVersion::ProductVersionId",
          "AssociationPropertyMetadata": {
            "RegionId": "${RegionId}"
          }
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      RegionId:
        Type: String
        AssociationProperty: ALIYUN::ECS::RegionId
      ProductVersionId:
        Type: String
        AssociationProperty: ALIYUN::ServiceCatalog::ProductVersion::ProductVersionId
        AssociationPropertyMetadata:
          RegionId: ${RegionId}
  • 示例说明

    示例中通过指定参数ProductVersionId的AssociationProperty属性为ALIYUN::ServiceCatalog::ProductVersion::ProductVersionId,AssociationPropertyMetadata属性为RegionId,获取当前可用地域下服务目录产品版本ID。

ALIYUN::User::Account::AccountIds

用户账号ID。

示例如下:

  • 示例代码

    JSON示例:

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
        "AccountIds": {
          "Type": "String",
          "AssociationProperty": "ALIYUN::User::Account::AccountIds"
        }
      }
    }

    YAML示例:

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters:
      AccountIds:
        Type: String
        AssociationProperty: ALIYUN::User::Account::AccountIds
  • 示例说明

    示例中通过指定参数AccountIds的AssociationProperty属性为ALIYUN::User::Account::AccountIds,获取用户账号ID。

AutoCompleteInput

自动生成随机字符串。

  • CharacterClasses

    • Class:字符类型。取值:

      • lowercase

      • uppercase

      • number

      • specialCharacter

    • Min:当前类型字符的最少个数。

    • SpecialCharacters:指定的特殊字符(当Class为specialCharacter时有效)。

    • Start:是否可以以特殊字符开头(当Class为specialCharacter时有效)。

    • End:是否可以以特殊字符结尾(当Class为specialCharacter时有效)。

  • Prefix:字符串前缀。

  • Suffix:字符串后缀。

  • Length:字符串长度。

示例代码

JSON示例:

{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "ManagedKubernetesClusterName": {
      "Type": "String",
      "Label": {
        "en": "Managed Kubernetes Cluster Name",
        "zh-cn": "ACK托管版集群名称"
      },
      "AssociationProperty": "AutoCompleteInput",
      "AssociationPropertyMetadata": {
        "Length": 5,
        "Prefix": "cluster-for-mse-",
        "Suffix": "-by-ros",
        "CharacterClasses": [
          {
            "Class": "lowercase",
            "min": 1
          }
        ]
      }
    }
  }
}

YAML示例:

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  ManagedKubernetesClusterName:
    Type: String
    Label:
      en: Managed Kubernetes Cluster Name
      zh-cn: ACK托管版集群名称
    AssociationProperty: AutoCompleteInput
    AssociationPropertyMetadata:
      Length: 5
      Prefix: cluster-for-mse-
      Suffix: '-by-ros'
      CharacterClasses:
        - Class: lowercase
          min: 1

ALIYUN::Flow::Connection::ConnectionId

获取云效中的服务连接列表。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • organizationId:企业标识,也称企业ID,字符串形式,可在云效访问链接中获取。例如,

    https://devops.aliyun.com/organization/[OrganizationId]
  • sericeConnectionType:服务连接类型。

示例代码

JSON示例:

{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "RegionId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::ECS::RegionId"
    },
    "OrganizationId": {
      "Type": "String"
    },
    "SericeConnectionType": {
      "Type": "String",
      "Default": "aliyun_code"
    },
    "ServiceConnectionId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::Flow::Connection::ConnectionId",
      "AssociationPropertyMetadata": {
        "RegionId": "${RegionId}",
        "organizationId": "${OrganizationId}",
        "sericeConnectionType": "${SericeConnectionType}"
      }
    }
  }
}

YAML示例:

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  RegionId:
    Type: String
    AssociationProperty: ALIYUN::ECS::RegionId
  OrganizationId:
    Type: String
  SericeConnectionType:
    Type: String
    Default: aliyun_code
  ServiceConnectionId:
    Type: String
    AssociationProperty: ALIYUN::Flow::Connection::ConnectionId
    AssociationPropertyMetadata:
      RegionId: ${RegionId}
      organizationId: ${OrganizationId}
      sericeConnectionType: ${SericeConnectionType}

ALIYUN::Flow::Organization::OrganizationId

查询当前用户的企业列表。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • accessLevel:用户权限。

  • minAccessLevel:最小用户权限,用于查询用户权限大于等于该字段设置的企业列表。

示例代码

JSON示例:

{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "RegionId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::ECS::RegionId"
    },
    "OrganizationId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::Flow::Organization::OrganizationId",
      "AssociationPropertyMetadata": {
        "RegionId": "${RegionId}",
        "accessLevel": 5,
        "minAccessLevel": 5
      }
    }
  }
}

YAML示例:

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  RegionId:
    Type: String
    AssociationProperty: ALIYUN::ECS::RegionId
  OrganizationId:
    Type: String
    AssociationProperty: ALIYUN::Flow::Organization::OrganizationId
    AssociationPropertyMetadata:
      RegionId: ${RegionId}
      accessLevel: 5
      minAccessLevel: 5

ALIYUN::ESS::ECIScalingConfiguration::ScalingConfigurationId

查询伸缩配置的ID。

  • RegionId:地域ID(默认为资源栈所属地域)。

  • ScalingGroupId:伸缩组的ID。

  • AutoSelectFirst:是否选择第一个。

示例代码

JSON示例:

{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "RegionId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::ECS::RegionId"
    },
    "AutoScalingGroupId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::ESS::AutoScalingGroup::AutoScalingGroupId",
      "AssociationPropertyMetadata": {
        "RegionId": "${RegionId}"
      }
    },
    "ServiceConnectionId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::ESS::ECIScalingConfiguration::ScalingConfigurationId",
      "AssociationPropertyMetadata": {
        "RegionId": "${RegionId}",
        "ScalingGroupId": "${AutoScalingGroupId}",
        "AutoSelectFirst": true
      }
    }
  }
}

YAML示例:

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  RegionId:
    Type: String
    AssociationProperty: ALIYUN::ECS::RegionId
  AutoScalingGroupId:
    Type: String
    AssociationProperty: ALIYUN::ESS::AutoScalingGroup::AutoScalingGroupId
    AssociationPropertyMetadata:
      RegionId: ${RegionId}
  ServiceConnectionId:
    Type: String
    AssociationProperty: ALIYUN::ESS::ECIScalingConfiguration::ScalingConfigurationId
    AssociationPropertyMetadata:
      RegionId: ${RegionId}
      ScalingGroupId: ${AutoScalingGroupId}
      AutoSelectFirst: true

ALIYUN::ECD::Bundle::DesktopType

查询云桌面规格详细信息。

  • RegionId:地域ID(默认为资源栈所属地域)。

示例代码

JSON示例:

{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "RegionId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::ECS::RegionId"
    },
    "DesktopType": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::ECD::Bundle::DesktopType",
      "AssociationPropertyMetadata": {
        "RegionId": "${RegionId}"
      }
    }
  }
}

YAML示例:

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  RegionId:
    Type: String
    AssociationProperty: ALIYUN::ECS::RegionId
  DesktopType:
    Type: String
    AssociationProperty: ALIYUN::ECD::Bundle::DesktopType
    AssociationPropertyMetadata:
      RegionId: ${RegionId}

ALIYUN::CEN::Instance::CenId

查询当前阿里云账号下的云企业网实例信息。

  • ResourceGroupId:云企业网实例所属的资源组ID。

示例代码

JSON示例:

{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "ResourceGroupId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::ECS::ResourceGroup::ResourceGroupId"
    },
    "CenId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::CEN::Instance::CenId",
      "AssociationPropertyMetadata": {
        "ResourceGroupId": "${ResourceGroupId}"
      }
    }
  }
}

YAML示例:

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  ResourceGroupId:
    Type: String
    AssociationProperty: ALIYUN::ECS::ResourceGroup::ResourceGroupId
  CenId:
    Type: String
    AssociationProperty: ALIYUN::CEN::Instance::CenId
    AssociationPropertyMetadata:
      ResourceGroupId: ${ResourceGroupId}

ALIYUN::CEN::TransitRouter::TransitRouterId

查询云企业网实例下转发路由器实例的信息。

  • RegionId: 地域ID(默认为资源栈所属地域)。

  • CenId:云企业网实例ID。

示例代码

JSON示例:

{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "RegionId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::ECS::RegionId"
    },
    "ResourceGroupId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::ECS::ResourceGroup::ResourceGroupId"
    },
    "CenId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::CEN::Instance::CenId",
      "AssociationPropertyMetadata": {
        "ResourceGroupId": "${ResourceGroupId}"
      }
    },
    "TransitRouterId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::CEN::TransitRouter::TransitRouterId",
      "AssociationPropertyMetadata": {
        "RegionId": "${RegionId}",
        "CenId": "${CenId}"
      }
    }
  }
}

YAML示例:

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  RegionId:
    Type: String
    AssociationProperty: ALIYUN::ECS::RegionId
  ResourceGroupId:
    Type: String
    AssociationProperty: ALIYUN::ECS::ResourceGroup::ResourceGroupId
  CenId:
    Type: String
    AssociationProperty: ALIYUN::CEN::Instance::CenId
    AssociationPropertyMetadata:
      ResourceGroupId: ${ResourceGroupId}
  TransitRouterId:
    Type: String
    AssociationProperty: ALIYUN::CEN::TransitRouter::TransitRouterId
    AssociationPropertyMetadata:
      RegionId: ${RegionId}
      CenId: ${CenId}

ALIYUN::User::AccountId

获取阿里云主账号ID。

示例代码

JSON示例:

{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "MasterAccountId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::User::AccountId"
    }
  }
}

YAML示例:

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  MasterAccountId:
    Type: String
    AssociationProperty: ALIYUN::User::AccountId

ALIYUN::User::UserId

获取当前阿里云用户ID。

示例代码

JSON示例:

{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "CurrentAccountId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::User::UserId"
    }
  }
}

YAML示例:

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  CurrentAccountId:
    Type: String
    AssociationProperty: ALIYUN::User::UserId

ALIYUN::Kafka::Instance::InstanceId

查询指定地域的Kafka实例信息。

  • RegionId: 地域ID(默认为资源栈所属地域)。

  • OrderId:订单ID。

示例代码

JSON示例:

{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "RegionId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::ECS::RegionId"
    },
    "InstanceId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::Kafka::Instance::InstanceId",
      "AssociationPropertyMetadata": {
        "RegionId": "${RegionId}"
      }
    }
  }
}

YAML示例:

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  RegionId:
    Type: String
    AssociationProperty: ALIYUN::ECS::RegionId
  InstanceId:
    Type: String
    AssociationProperty: ALIYUN::Kafka::Instance::InstanceId
    AssociationPropertyMetadata:
      RegionId: ${RegionId}

ALIYUN::Emr::ECSCluster::ClusterId

查询EMR集群列表。

  • RegionId: 地域ID(默认为资源栈所属地域)。

  • ClusterTypes:集群类型列表。取值:

    • DATALAKE:新版数据湖。

    • OLAP:数据分析。

    • DATAFLOW:实时数据流。

    • DATASERVING:数据服务。

    • CUSTOM:自定义混部集群。

    • HADOOP:旧版数据湖。

  • ClusterStates:集群状态数组。取值:

    • STARTING:启动中。

    • START_FAILED:启动失败。

    • BOOTSTRAPPING:引导操作初始化。

    • RUNNING:运行中。

    • TERMINATING:终止中。

    • TERMINATED:已终止。

    • TERMINATED_WITH_ERRORS:发生异常导致终止

    • TERMINATE_FAILED:终止失败。

  • PaymentTypes:付费类型。取值:

    • Subscription:预付费。

    • PayAsYouGo:后付费。

示例代码

JSON示例:

{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "RegionId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::ECS::RegionId"
    },
    "ClusterId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::Emr::ECSCluster::ClusterId",
      "AssociationPropertyMetadata": {
        "RegionId": "${RegionId}",
        "PaymentTypes": [
          "PayAsYouGo"
        ]
      }
    }
  }
}

YAML示例:

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  RegionId:
    Type: String
    AssociationProperty: ALIYUN::ECS::RegionId
  ClusterId:
    Type: String
    AssociationProperty: ALIYUN::Emr::ECSCluster::ClusterId
    AssociationPropertyMetadata:
      RegionId: ${RegionId}
      PaymentTypes:
        - PayAsYouGo

ALIYUN::Lindorm::Instance::InstanceId

获取Lindorm实例列表。

  • RegionId: 地域ID(默认为资源栈所属地域)。

  • SupportEngine:查询的实例支持的数据引擎类型,取值:

    • 1:支持搜索引擎。

    • 2:支持时序引擎。

    • 4:支持宽表引擎。

    • 8:支持文件引擎。

  • ServiceType:实例类型,取值:

    • lindorm:表示Lindorm单可用区实例。

    • lindorm_multizone:表示Lindorm多可用区实例。

    • serverless_lindorm:表示Lindorm Serverless实例。

    • lindorm_standalone:表示Lindorm单节点实例。

    • lts:表示Lindorm数据通道服务类型。

示例代码

JSON示例:

{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "RegionId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::ECS::RegionId"
    },
    "LindormInstanceId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::Lindorm::Instance::InstanceId",
      "AssociationPropertyMetadata": {
        "RegionId": "${RegionId}",
        "SupportEngine": 1,
        "ServiceType": "lindorm"
      }
    }
  }
}

YAML示例:

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  RegionId:
    Type: String
    AssociationProperty: ALIYUN::ECS::RegionId
  LindormInstanceId:
    Type: String
    AssociationProperty: ALIYUN::Lindorm::Instance::InstanceId
    AssociationPropertyMetadata:
      RegionId: ${RegionId}
      SupportEngine: 1
      ServiceType: lindorm

ALIYUN::BSS::PricingModule::ModuleCode

查询阿里云某个产品对应模块信息。

  • RegionId: 地域ID(默认为资源栈所属地域)。

  • ProductCode: 产品代码。

  • ProductType: 产品类型。

  • SubscriptionType: 订阅类型。取值:

    • Subscription:预付费。

    • PayAsYouGo:后付费。

示例代码

JSON示例:

{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "RegionId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::ECS::RegionId"
    },
    "PricingModule": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::BSS::PricingModule::ModuleCode",
      "AssociationPropertyMetadata": {
        "RegionId": "${RegionId}",
        "ProductCode": "rds",
        "ProductType": "rds",
        "SubscriptionType": "PayAsYouGo"
      }
    }
  }
}

YAML示例:

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  RegionId:
    Type: String
    AssociationProperty: ALIYUN::ECS::RegionId
  PricingModule:
    Type: String
    AssociationProperty: ALIYUN::BSS::PricingModule::ModuleCode
    AssociationPropertyMetadata:
      RegionId: ${RegionId}
      ProductCode: rds
      ProductType: rds
      SubscriptionType: PayAsYouGo

ALIYUN::NAS::FileSystem::FileSystemId

查询文件系统信息。

  • RegionId: 地域ID(默认为资源栈所属地域)。

  • FileSystemType: 文件系统类型。取值:

    • all(默认值):所有类型。

    • standard:通用型NAS。

    • extreme:极速型NAS。

    • cpfs:CPFS。

  • VpcId:专有网络ID。

示例代码

JSON示例:

{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "RegionId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::ECS::RegionId"
    },
    "VpcId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::ECS::VPC::VPCId",
      "AssociationPropertyMetadata": {
        "RegionId": "${RegionId}"
      }
    },
    "NASFileSystemId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::NAS::FileSystem::FileSystemId",
      "AssociationPropertyMetadata": {
        "RegionId": "${RegionId}",
        "FileSystemType": "all",
        "VpcId": "PayAsYouGo"
      }
    }
  }
}

YAML示例:

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  RegionId:
    Type: String
    AssociationProperty: ALIYUN::ECS::RegionId
  VpcId:
    Type: String
    AssociationProperty: ALIYUN::ECS::VPC::VPCId
    AssociationPropertyMetadata:
      RegionId: ${RegionId}
  NASFileSystemId:
    Type: String
    AssociationProperty: ALIYUN::NAS::FileSystem::FileSystemId
    AssociationPropertyMetadata:
      RegionId: ${RegionId}
      FileSystemType: all
      VpcId: PayAsYouGo

ALIYUN::NAS::FileSystem::MountTargetDomain

查询挂载点地址。

  • RegionId: 地域ID(默认为资源栈所属地域)。

  • FileSystemId:文件系统ID。

示例代码

JSON示例:

{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "RegionId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::ECS::RegionId"
    },
    "VpcId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::ECS::VPC::VPCId",
      "AssociationPropertyMetadata": {
        "RegionId": "${RegionId}"
      }
    },
    "NASFileSystemId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::NAS::FileSystem::FileSystemId",
      "AssociationPropertyMetadata": {
        "RegionId": "${RegionId}",
        "FileSystemType": "all",
        "VpcId": "PayAsYouGo"
      }
    },
    "NASMountTarget": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::NAS::FileSystem::MountTargetDomain",
      "AssociationPropertyMetadata": {
        "RegionId": "${RegionId}",
        "FileSystemId": "${NASFileSystemId}"
      }
    }
  }
}

YAML示例:

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  RegionId:
    Type: String
    AssociationProperty: ALIYUN::ECS::RegionId
  VpcId:
    Type: String
    AssociationProperty: ALIYUN::ECS::VPC::VPCId
    AssociationPropertyMetadata:
      RegionId: ${RegionId}
  NASFileSystemId:
    Type: String
    AssociationProperty: ALIYUN::NAS::FileSystem::FileSystemId
    AssociationPropertyMetadata:
      RegionId: ${RegionId}
      FileSystemType: all
      VpcId: PayAsYouGo
  NASMountTarget:
    Type: String
    AssociationProperty: ALIYUN::NAS::FileSystem::MountTargetDomain
    AssociationPropertyMetadata:
      RegionId: ${RegionId}
      FileSystemId: ${NASFileSystemId}

示例1:AssociationProperty示例

在参数中指定AssociationProperty取值为ALIYUN::ECS::Image::ImageId,以获取所选地域下所有的镜像ID。

JSON示例:

{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "UserName": {
      "Label": "用户名",
      "Description": "请输入用户名",
      "Default": "anonymous",
      "Type": "String",
      "MinLength": "6",
      "MaxLength": "12",
      "AllowedValues": [
        "anonymous",
        "user-one",
        "user-two"
      ]
    },
    "PassWord": {
      "Label": "密码",
      "NoEcho": "True",
      "Description": "请输入用户密码",
      "Type": "String",
      "MinLength": "1",
      "MaxLength": "41",
      "AllowedPattern": "[a-zA-Z0-9]*"
    },
    "ImageId": {
      "Label": "镜像",
      "Type": "String",
      "Description": "请选择镜像",
      "AssociationProperty": "ALIYUN::ECS::Image::ImageId",
      "Default": "centos_7_7_x64_20G_alibase_2020****.vhd"
    }
  }
}

YAML示例:

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  UserName:
    Label: 用户名
    Description: 请输入用户名
    Default: anonymous
    Type: String
    MinLength: '6'
    MaxLength: '12'
    AllowedValues:
      - anonymous
      - user-one
      - user-two
  PassWord:
    Label: 密码
    NoEcho: 'True'
    Description: 请输入用户密码
    Type: String
    MinLength: '1'
    MaxLength: '41'
    AllowedPattern: '[a-zA-Z0-9]*'
  ImageId:
    Label: 镜像
    Type: String
    Description: 请选择镜像
    AssociationProperty: ALIYUN::ECS::Image::ImageId
    Default: centos_7_7_x64_20G_alibase_2020****.vhd

参数说明:

  • UserName:用户名。String类型,长度为6~12个字符,取值:

    • anonymous(默认值)

    • user-one

    • user-two

  • PassWord:密码。String类型,无默认值。长度为1~41个字符,支持大写英文字母、小写英文字母和数字。

    NoEcho取值为true,表示查询资源栈时将不会返回参数值。

  • ImageId:镜像ID。String类型。

    AssociationProperty取值为ALIYUN::ECS::Image::ImageId,创建资源栈时ROS控制台将会验证参数指定的镜像ID是否可用,并以下拉框的方式列出所选地域的其他镜像ID取值。

示例2:AssociationPropertyMetadata示例

在参数中指定AssociationProperty和对应的AssociationPropertyMetadata(RegionId、VpcId和ZoneId),以便获取指定专有网络和可用区的交换机。其中,RegionId取值为固定值cn-hangzhou;VpcId和ZoneId取值为变量${VpcId}和${EcsZone},将根据ALIYUN::ECS::VPC::VPCId和ZoneId选定的取值进行动态刷新,从而建立交换机与专有网络和可用区的关联关系。

JSON示例:

{
 "ROSTemplateFormatVersion": "2015-09-01",
 "Parameters": {
  "VpcId": {
   "Type": "String",
   "AssociationProperty": "ALIYUN::ECS::VPC::VPCId"
  },
  "EcsZone": {
   "Type": "String",
   "AssociationProperty": "ZoneId"
  },
  "VSwitchId": {
   "Type": "String",
   "AssociationProperty": "ALIYUN::VPC::VSwitch::VSwitchId",
   "AssociationPropertyMetadata": {
           "RegionId": "cn-hangzhou",
           "VpcId": "${VpcId}",
           "ZoneId": "${EcsZone}"
   }
  }
 }
}

YAML示例:

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  VpcId:
    Type: String
    AssociationProperty: ALIYUN::ECS::VPC::VPCId
  EcsZone:
    Type: String
    AssociationProperty: ZoneId
  VSwitchId:
    Type: String
    AssociationProperty: ALIYUN::VPC::VSwitch::VSwitchId
    AssociationPropertyMetadata:
      RegionId: cn-hangzhou
      VpcId: ${VpcId}
      ZoneId: ${EcsZone}

示例3:Terraform自动转换示例

当AssociationProperty取值为Auto时,ROS会基于Terraform原始数据结构,自动生成AssociationProperty和AssociationPropertyMetadata等字段。

  • 完整模板示例代码

    variable "user_information" {
      type = object({
        name    = string
        address = string
      })
      description = <<EOT
      {
        "AssociationProperty": "Auto",
        "AssociationPropertyMetadata": {
          "Overwrite": {
            "name": {
              "Label": {
                "zh-cn": "姓名",
                "en": "Name"
              }
            }
          }
        }
      }
      EOT
    }
    
    variable "region_ids" {
      type    = list(string)
      description = <<EOT
      {
        "AssociationProperty": "Auto",
        "AssociationPropertyMetadata": {
          "Overwrite": {
            "*": {
              "AssociationProperty": "ALIYUN::ECS::RegionId"
            }
          }
        }
      }
      EOT
    }
    
    variable "docker_ports" {
      type = list(object({
        internal = number
        external = number
        protocol = string
      }))
      description = <<EOT
      {
        "AssociationProperty": "Auto",
        "AssociationPropertyMetadata": {
          "Overwrite": {
            "protocol": {
              "AllowedValues": ["TCP", "UDP", "ICMP"]
            },
            "internal": {
              "Label": {
                "zh-cn": "内部端口",
                "en": "Internal Port"
              }
            }
          }
        }
      }
      EOT
    }
    
    variable "complex_type_demo" {
      type = list(object({
        b = list(string)
        c = list(object({
          d = list(string)
        }))
        e = list(list(string))
        f = list(list(object({
          g = list(string)
        })))
      }))
      description = <<EOT
      {
        "AssociationProperty": "Auto",
        "AssociationPropertyMetadata": {
            "Overwrite": {
                "b": {
                    "MaxLength": 3,
                    "AssociationPropertyMetadata": {
                        "Something": "123"
                    },
                    "Label": {
                        "zh-cn": "B",
                        "en": "B"
                    }
                },
                "b.*": {
                    "AssociationProperty": "ALIYUN::ECS::RegionId"
                },
                "c": {
                    "Label": {
                        "zh-cn": "C",
                        "en": "C"
                    }
                },
                "c.d": {
                    "Label": {
                        "zh-cn": "C/D",
                        "en": "C/D"
                    }
                },
                "c.d.*": {
                    "AssociationProperty": "ALIYUN::ECS::RegionId"
                },
                "e": {
                    "Label": {
                        "zh-cn": "E",
                        "en": "E"
                    }
                },
                "e.*": {
                    "MaxLength": 3
                },
                "e.*.*": {
                    "AssociationProperty": "ALIYUN::ECS::RegionId"
                },
                "f.g": {
                    "Label": {
                        "zh-cn": "F/G",
                        "en": "F/G"
                    }
                },
                "f.g.*": {
                    "AssociationProperty": "ALIYUN::ECS::RegionId"
                }
            }
        }
      }
      EOT
    }
  • 参数user_information转换后模板示例代码

    {
      "AssociationPropertyMetadata":{
        "Parameters":{
          "address":{
            "Type":"String"
          },
          "name":{
            "Type":"String",
            "Label":{
              "en":"Name",
              "zh-cn":"姓名"
            }
          }
        }
      }
    }
  • 参数region_ids转换后模板示例代码

    {
      "AssociationPropertyMetadata":{
        "Parameter":{
          "AssociationProperty":"ALIYUN::ECS::RegionId",
          "Type":"String"
        }
      },
      "AssociationProperty":"List[Parameter]"
    }
  • 参数docker_ports转换后模板示例代码

    {
      "AssociationPropertyMetadata":{
        "Parameters":{
          "internal":{
            "Type":"Number",
            "Label":{
              "en":"Internal Port",
              "zh-cn":"内部端口"
            }
          },
          "protocol":{
            "Type":"String",
            "AllowedValues":[
              "TCP",
              "UDP",
              "ICMP"
            ]
          },
          "external":{
            "Type":"Number"
          }
        }
      },
      "AssociationProperty":"List[Parameters]"
    }
  • 参数complex_type_demo转换后模板示例代码

    {
      "AssociationPropertyMetadata":{
        "Parameter":{
          "AssociationPropertyMetadata":{
            "Parameters":{
              "b":{
                "AssociationPropertyMetadata":{
                  "Parameter":{
                    "AssociationProperty":"ALIYUN::ECS::RegionId",
                    "Type":"String"
                  },
                  "Something":"123"
                },
                "AssociationProperty":"List[Parameter]",
                "Type":"Json",
                "Label":{
                  "en":"B",
                  "zh-cn":"B"
                },
                "MaxLength":3
              },
              "c":{
                "AssociationPropertyMetadata":{
                  "Parameter":{
                    "AssociationPropertyMetadata":{
                      "Parameters":{
                        "d":{
                          "AssociationPropertyMetadata":{
                            "Parameter":{
                              "AssociationProperty":"ALIYUN::ECS::RegionId",
                              "Type":"String"
                            }
                          },
                          "AssociationProperty":"List[Parameter]",
                          "Type":"Json",
                          "Label":{
                            "en":"C/D",
                            "zh-cn":"C/D"
                          }
                        }
                      }
                    },
                    "Type":"Json"
                  }
                },
                "AssociationProperty":"List[Parameter]",
                "Type":"Json",
                "Label":{
                  "en":"C",
                  "zh-cn":"C"
                }
              },
              "e":{
                "AssociationPropertyMetadata":{
                  "Parameter":{
                    "AssociationPropertyMetadata":{
                      "Parameter":{
                        "AssociationProperty":"ALIYUN::ECS::RegionId",
                        "Type":"String"
                      }
                    },
                    "AssociationProperty":"List[Parameter]",
                    "Type":"Json",
                    "MaxLength":3
                  }
                },
                "AssociationProperty":"List[Parameter]",
                "Type":"Json",
                "Label":{
                  "en":"E",
                  "zh-cn":"E"
                }
              },
              "f":{
                "AssociationPropertyMetadata":{
                  "Parameter":{
                    "AssociationPropertyMetadata":{
                      "Parameter":{
                        "AssociationPropertyMetadata":{
                          "Parameters":{
                            "g":{
                              "AssociationPropertyMetadata":{
                                "Parameter":{
                                  "AssociationProperty":"ALIYUN::ECS::RegionId",
                                  "Type":"String"
                                }
                              },
                              "AssociationProperty":"List[Parameter]",
                              "Type":"Json",
                              "Label":{
                                "en":"F/G",
                                "zh-cn":"F/G"
                              }
                            }
                          }
                        },
                        "Type":"Json"
                      }
                    },
                    "AssociationProperty":"List[Parameter]",
                    "Type":"Json"
                  }
                },
                "AssociationProperty":"List[Parameter]",
                "Type":"Json"
              }
            }
          },
          "Type":"Json"
        }
      },
      "AssociationProperty":"List[Parameter]"
    }

更多示例

您也可以使用AssociationProperty和AssociationPropertyMetadata,实现以下诉求: