ALIYUN::CMS::MonitorGroupInstances类型用于添加资源到应用分组。
语法
{
"Type": "ALIYUN::CMS::MonitorGroupInstances",
"Properties": {
"Instances": List,
"GroupId": Integer
}
}
属性
属性名称 | 类型 | 必须 | 允许更新 | 描述 | 约束 |
---|---|---|---|---|---|
Instances | List | 是 | 否 | 资源实例 | 更多信息,请参见Instances属性。 |
GroupId | Integer | 是 | 否 | 应用分组ID | 无 |
Instances语法
"Instances": [
{
"InstanceName": String,
"Category": String,
"InstanceId": String,
"RegionId": String
}
]
Instances属性
属性名称 | 类型 | 必须 | 允许更新 | 描述 | 约束 |
---|---|---|---|---|---|
InstanceName | String | 是 | 否 | 实例名称。 | 无 |
Category | String | 是 | 否 | 资源实例所属的云产品名称或规格。 | 取值:
|
InstanceId | String | 是 | 否 | 资源实例ID。 | 无 |
RegionId | String | 是 | 否 | 实例所在的地域ID。 | 无 |
返回值
Fn::GetAtt
GroupId:应用分组ID。
示例
JSON
格式
{
"ROSTemplateFormatVersion": "2015-09-01",
"Parameters": {
"Instances": {
"Type": "Json"
},
"GroupId": {
"Type": "Number",
"Description": "The ID of the application group."
}
},
"Resources": {
"MonitorGroupInstances": {
"Type": "ALIYUN::CMS::MonitorGroupInstances",
"Properties": {
"Instances": {
"Ref": "Instances"
},
"GroupId": {
"Ref": "GroupId"
}
}
}
},
"Outputs": {
"GroupId": {
"Description": "The ID of the application group.",
"Value": {
"Fn::GetAtt": [
"MonitorGroupInstances",
"GroupId"
]
}
}
}
}
YAML
格式
ROSTemplateFormatVersion: '2015-09-01'
Parameters:
Instances:
Type: Json
GroupId:
Type: Number
Description: The ID of the application group.
Resources:
MonitorGroupInstances:
Type: 'ALIYUN::CMS::MonitorGroupInstances'
Properties:
Instances:
Ref: Instances
GroupId:
Ref: GroupId
Outputs:
GroupId:
Description: The ID of the application group.
Value:
'Fn::GetAtt':
- MonitorGroupInstances
- GroupId
在文档使用中是否遇到以下问题
更多建议
匿名提交