ALIYUN::BastionHost::UserGroup类型用于创建用户组。
语法
{
"Type": "ALIYUN::BastionHost::UserGroup",
"Properties": {
"InstanceId": String,
"UserGroupName": String,
"Comment": String
}
}
属性
|
属性名称 |
类型 |
必须 |
允许更新 |
描述 |
约束 |
|
InstanceId |
String |
是 |
否 |
堡垒主机实例的ID。 |
无 |
|
UserGroupName |
String |
是 |
否 |
用户组的名称。 |
无 |
|
Comment |
String |
否 |
否 |
用户组的备注。 |
无 |
返回值
Fn::GetAtt
UserGroupId:用户组的ID。
示例
ROSTemplateFormatVersion: '2015-09-01'
Parameters:
InstanceId:
Type: String
Description:
en: The ID of the BastionHost instance.
zh: 堡垒主机实例的ID。
Required: true
UserGroupName:
Type: String
Description:
en: The name of the user group.
zh: 用户组的名称。
Required: true
Resources:
UserGroup:
Type: ALIYUN::BastionHost::UserGroup
Properties:
InstanceId:
Ref: InstanceId
UserGroupName:
Ref: UserGroupName
Outputs:
UserGroupId:
Description:
en: The ID of the user group.
zh: 用户组的ID。
Value:
Fn::GetAtt:
- UserGroup
- UserGroupId
{
"ROSTemplateFormatVersion": "2015-09-01",
"Parameters": {
"InstanceId": {
"Type": "String",
"Description": {
"en": "The ID of the BastionHost instance.",
"zh": "堡垒主机实例的ID。"
},
"Required": true
},
"UserGroupName": {
"Type": "String",
"Description": {
"en": "The name of the user group.",
"zh": "用户组的名称。"
},
"Required": true
}
},
"Resources": {
"UserGroup": {
"Type": "ALIYUN::BastionHost::UserGroup",
"Properties": {
"InstanceId": {
"Ref": "InstanceId"
},
"UserGroupName": {
"Ref": "UserGroupName"
}
}
}
},
"Outputs": {
"UserGroupId": {
"Description": {
"en": "The ID of the user group.",
"zh": "用户组的ID。"
},
"Value": {
"Fn::GetAtt": [
"UserGroup",
"UserGroupId"
]
}
}
}
}
该文章对您有帮助吗?