ALIYUN::Config::Aggregator类型用于创建一个账号组。
语法
{
"Type": "ALIYUN::Config::Aggregator",
"Properties": {
"AggregatorName": String,
"Description": String,
"AggregatorAccounts": List,
"AggregatorType": String
}
}
属性
属性名称 | 类型 | 必须 | 允许更新 | 描述 | 约束 |
AggregatorName | String | 是 | 是 | 账号组名称。 | 无 |
Description | String | 是 | 是 | 账号组描述。 | 无 |
AggregatorAccounts | List | 否 | 是 | 账号组内的所有成员账号。 | 更多信息,请参见AggregatorAccounts属性。 示例:
|
AggregatorType | String | 否 | 否 | 账号组类型。 | 取值:
|
AggregatorAccounts语法
"AggregatorAccounts": [
{
"AccountId": Number,
"AccountType": String,
"AccountName": String
}
]
AggregatorAccounts属性
属性名称 | 类型 | 必须 | 允许更新 | 描述 | 约束 |
AccountId | Number | 是 | 是 | 成员账号ID。 | 无 |
AccountName | String | 是 | 是 | 成员账号名称。 | 无 |
AccountType | String | 否 | 是 | 成员账号归属。 | 仅支持ResourceDirectory(资源目录)。 |
返回值
Fn::GetAtt
AggregatorId:账号组ID。
示例
YAML
ROSTemplateFormatVersion: '2015-09-01'
Parameters:
AggregatorAccounts:
AssociationProperty: List[Parameters]
AssociationPropertyMetadata:
Parameters:
AccountId:
Description:
en: The account id.
Required: true
Type: Number
AccountName:
Description:
en: The account name.
Required: true
Type: String
AccountType:
AllowedValues:
- ResourceDirectory
Default: ResourceDirectory
Description:
en: 'The account type. Only support: ResourceDirectory'
Required: false
Type: String
Description:
en: The member account in aggregator.When the AggregatorType is RD, this parameter
can be empty, which means that all accounts in the resource directory will
be added to the global account group.
Required: false
Type: Json
AggregatorName:
Description:
en: The name of aggregator.
Required: true
Type: String
AggregatorType:
AllowedValues:
- RD
- CUSTOM
Description:
en: 'Account group type. Value:
RD: Global account group.CUSTOM: Custom account group (default value).'
Required: false
Type: String
Description:
AssociationProperty: TextArea
Description:
en: The description of aggregator.
Required: true
Type: String
Resources:
Aggregator:
Properties:
AggregatorAccounts:
Ref: AggregatorAccounts
AggregatorName:
Ref: AggregatorName
AggregatorType:
Ref: AggregatorType
Description:
Ref: Description
Type: ALIYUN::Config::Aggregator
Outputs:
AggregatorId:
Description: 'The ID of the aggregator. '
Value:
Fn::GetAtt:
- Aggregator
- AggregatorId
JSON
{
"ROSTemplateFormatVersion": "2015-09-01",
"Parameters": {
"AggregatorName": {
"Type": "String",
"Description": {
"en": "The name of aggregator."
},
"Required": true
},
"Description": {
"AssociationProperty": "TextArea",
"Type": "String",
"Description": {
"en": "The description of aggregator."
},
"Required": true
},
"AggregatorAccounts": {
"AssociationPropertyMetadata": {
"Parameters": {
"AccountId": {
"Type": "Number",
"Description": {
"en": "The account id."
},
"Required": true
},
"AccountType": {
"Type": "String",
"Description": {
"en": "The account type. Only support: ResourceDirectory"
},
"AllowedValues": [
"ResourceDirectory"
],
"Required": false,
"Default": "ResourceDirectory"
},
"AccountName": {
"Type": "String",
"Description": {
"en": "The account name."
},
"Required": true
}
}
},
"AssociationProperty": "List[Parameters]",
"Type": "Json",
"Description": {
"en": "The member account in aggregator.When the AggregatorType is RD, this parameter can be empty, which means that all accounts in the resource directory will be added to the global account group."
},
"Required": false
},
"AggregatorType": {
"Type": "String",
"Description": {
"en": "Account group type. Value:\nRD: Global account group.CUSTOM: Custom account group (default value)."
},
"AllowedValues": [
"RD",
"CUSTOM"
],
"Required": false
}
},
"Resources": {
"Aggregator": {
"Type": "ALIYUN::Config::Aggregator",
"Properties": {
"AggregatorName": {
"Ref": "AggregatorName"
},
"Description": {
"Ref": "Description"
},
"AggregatorAccounts": {
"Ref": "AggregatorAccounts"
},
"AggregatorType": {
"Ref": "AggregatorType"
}
}
}
},
"Outputs": {
"AggregatorId": {
"Description": "The ID of the aggregator. ",
"Value": {
"Fn::GetAtt": [
"Aggregator",
"AggregatorId"
]
}
}
}
}