ALIYUN::ApiGateway::Instance类型用于创建专享实例。
语法
{
"Type": "ALIYUN::ApiGateway::Instance",
"Properties": {
"InstanceName": String,
"DeletionForce": Boolean,
"InstanceSpec": String,
"HttpsPolicy": String,
"ZoneId": String,
"PricingCycle": String,
"ChargeType": String,
"Duration": Number,
"AutoPay": Boolean,
"Tags": List
}
}
属性
属性名称 | 类型 | 必须 | 允许更新 | 描述 | 约束 |
---|---|---|---|---|---|
InstanceName | String | 是 | 否 | 实例名称。 | 长度为1~50个字符,可包含汉字、英文字母、数字和特殊字符-/._ 。 |
DeletionForce | Boolean | 否 | 否 | 是否强制删除实例。 | 取值:
|
InstanceSpec | String | 是 | 否 | 实例规格。 | 更多信息,请参见专享实例。 |
HttpsPolicy | String | 是 | 否 | HTTPS安全策略。 | 取值:
更多信息,请参见HTTPS安全策略。 |
ZoneId | String | 是 | 否 | 可用区ID。 | 无 |
PricingCycle | String | 否 | 否 | 预付费实例的付费周期。 | 取值:
|
ChargeType | String | 否 | 否 | 付费类型。 | 取值:
|
Duration | Number | 否 | 否 | 付费时长。 | 取值:
|
AutoPay | Boolean | 否 | 否 | 到期是否自动续费。 | 取值:
|
Tags | List | 否 | 是 | 标签。 | 最多添加20个标签。 更多信息,请参见Tags属性。 |
Tags语法
"Tags": [
{
"Key": String,
"Value": String
}
]
Tags属性
属性名称 | 类型 | 必须 | 允许更新 | 描述 | 约束 |
---|---|---|---|---|---|
Key | String | 是 | 否 | 标签键。 | 长度为1~128个字符,不能以aliyun 和acs: 开头,不能包含http:// 或https:// 。 |
Value | String | 否 | 否 | 标签值。 | 长度为0~128个字符,不能以aliyun 和acs: 开头,不能包含http:// 或https:// 。 |
返回值
Fn::GetAtt
- InstanceType:实例类型。
- InstanceId:实例ID。
- VpcEgressAddress:专有网络出口地址。
- InternetEgressAddress:公网出口地址。
- EgressIpv6Enable:IPv6出访能力。
- VpcIntranetEnable:是否支持专有网络。
- SupportIpv6:是否支持IPv6。
- VpcSlbIntranetEnable:是否支持VPC类型SLB。
示例
JSON
格式{ "Parameters": { "InstanceName": { "Type": "String", "Description": "Instance name" }, "ZoneId": { "Type": "String", "AssociationProperty": "ZoneId" } }, "ROSTemplateFormatVersion": "2015-09-01", "Outputs": { "EgressIpv6Enable": { "Description": "Whether enable egress IPv6.", "Value": { "Fn::GetAtt": [ "Instance", "EgressIpv6Enable" ] } }, "VpcEgressAddress": { "Description": "VPC network egress address.", "Value": { "Fn::GetAtt": [ "Instance", "VpcEgressAddress" ] } }, "InternetEgressAddress": { "Description": "Internet egress dddress.", "Value": { "Fn::GetAtt": [ "Instance", "InternetEgressAddress" ] } }, "InstanceId": { "Description": "Instance ID.", "Value": { "Fn::GetAtt": [ "Instance", "InstanceId" ] } }, "VpcIntranetEnable": { "Description": "Whether enable VPC intranet.", "Value": { "Fn::GetAtt": [ "Instance", "VpcIntranetEnable" ] } }, "SupportIpv6": { "Description": "Whether support IPv6.", "Value": { "Fn::GetAtt": [ "Instance", "SupportIpv6" ] } }, "InstanceType": { "Description": "Instance type.", "Value": { "Fn::GetAtt": [ "Instance", "InstanceType" ] } }, "VpcSlbIntranetEnable": { "Description": "Whether enable VPC SLB intranet.", "Value": { "Fn::GetAtt": [ "Instance", "VpcSlbIntranetEnable" ] } } }, "Resources": { "Instance": { "Type": "ALIYUN::ApiGateway::Instance", "Properties": { "InstanceName": "TestInstance", "InstanceSpec": "api.s1.small", "HttpsPolicy": "HTTPS2_TLS1_0", "ZoneId": { "Ref": "ZoneId" } } } } }
更多示例,请参见:JSON示例。