ALIYUN::CDDC::DedicatedHostAccount类型用于创建专用主机帐户。
语法
{
"Type": "ALIYUN::CDDC::DedicatedHostAccount",
"Properties": {
"AccountPassword": String,
"AccountName": String,
"DedicatedHostId": String,
"AccountType": String,
"BastionInstanceId": String
}
}
属性
|
属性名称 |
类型 |
必须 |
允许更新 |
描述 |
约束 |
|
AccountName |
String |
是 |
否 |
账户的名称。 |
长度限制:最小2,最大16 |
|
AccountPassword |
String |
是 |
否 |
账户的密码。 |
无 |
|
DedicatedHostId |
String |
是 |
否 |
专有主机的ID。 |
无 |
|
AccountType |
String |
否 |
否 |
账户的类型。 |
可选值:Normal(普通)、Admin(管理员) |
|
BastionInstanceId |
String |
否 |
否 |
堡垒主机实例的ID。 |
无 |
返回值
Fn::GetAtt
无
示例
ROSTemplateFormatVersion: '2015-09-01'
Parameters:
DedicatedHostId:
Type: String
Description:
en: The ID of the dedicated host.
zh: 专有主机的ID。
Required: true
AccountName:
Type: String
Description:
en: The name of the account.
zh: 账户的名称。
Required: true
AllowedPattern: ^[a-z][a-z0-9_]{0,14}[a-z0-9]$
MinLength: 2
MaxLength: 16
AccountPassword:
Type: String
Description:
en: The password of the account.
zh: 账户的密码。
Required: true
Resources:
DedicatedHostAccount:
Type: ALIYUN::CDDC::DedicatedHostAccount
Properties:
DedicatedHostId:
Ref: DedicatedHostId
AccountName:
Ref: AccountName
AccountPassword:
Ref: AccountPassword
{
"ROSTemplateFormatVersion": "2015-09-01",
"Parameters": {
"DedicatedHostId": {
"Type": "String",
"Description": {
"en": "The ID of the dedicated host.",
"zh": "专有主机的ID。"
},
"Required": true
},
"AccountName": {
"Type": "String",
"Description": {
"en": "The name of the account.",
"zh": "账户的名称。"
},
"Required": true,
"AllowedPattern": "^[a-z][a-z0-9_]{0,14}[a-z0-9]$",
"MinLength": 2,
"MaxLength": 16
},
"AccountPassword": {
"Type": "String",
"Description": {
"en": "The password of the account.",
"zh": "账户的密码。"
},
"Required": true
}
},
"Resources": {
"DedicatedHostAccount": {
"Type": "ALIYUN::CDDC::DedicatedHostAccount",
"Properties": {
"DedicatedHostId": {
"Ref": "DedicatedHostId"
},
"AccountName": {
"Ref": "AccountName"
},
"AccountPassword": {
"Ref": "AccountPassword"
}
}
}
}
}
该文章对您有帮助吗?