ALIYUN::VPC::CommonBandwidthPackage類型用於建立共用頻寬執行個體。
本資源僅支援建立隨用隨付共用頻寬執行個體。
文法
{
"Type": "ALIYUN::VPC::CommonBandwidthPackage",
"Properties": {
"Description": String,
"Zone": String,
"ISP": String,
"ResourceGroupId": String,
"Bandwidth": Integer,
"InternetChargeType": String,
"Name": String,
"DeletionProtection": Boolean
"Tags": List
}
}屬性
屬性名稱 | 類型 | 必須 | 允許更新 | 描述 | 約束 |
Description | String | 否 | 是 | 共用頻寬的描述資訊。 | 長度為2~256個字元,必須以英文字母或漢字開頭,但不能以 |
Zone | String | 否 | 否 | 共用頻寬的可用性區域。 | 不需要指定該參數。 |
ISP | String | 否 | 否 | EIP的線路類型。 | 取值:BGP(多線)。 |
ResourceGroupId | String | 否 | 是 | 資源群組ID。 | 無 |
Bandwidth | Integer | 是 | 是 | 共用頻寬的頻寬峰值。 | 取值範圍:2~5000。 單位:Mbps。 |
InternetChargeType | String | 否 | 否 | 共用頻寬的計費方式。 | 取值範圍:
|
Name | String | 否 | 是 | 共用頻寬的名稱。 | 長度為2~128個字元。必須以英文字母或漢字開頭,但不能以 |
Tags | List | 否 | 是 | 標籤。 | 最多支援添加20個標籤。 更多資訊,請參見Tags屬性。 |
DeletionProtection | Boolean | 否 | 是 | 是否啟用刪除保護。 | 取值:
|
Tags文法
"Tags": [
{
"Key": String,
"Value": String
}
] Tags屬性
屬性名稱 | 類型 | 必須 | 允許更新 | 描述 | 約束 |
Key | String | 是 | 否 | 標籤鍵。 | 長度為1~128個字元,不能以 |
Value | String | 否 | 否 | 標籤值。 | 長度為0~128個字元,不能以 |
傳回值
Fn::GetAtt
BandwidthPackageId:共用頻寬執行個體的ID。
Arn:阿里雲資源名稱。
樣本
ROSTemplateFormatVersion: '2015-09-01'
Parameters: {}
Resources:
CommonBandwidthPackage:
Type: ALIYUN::VPC::CommonBandwidthPackage
Properties:
Description: Test
Name: test-dsa
Bandwidth: 5
InternetChargeType: PayByBandwidth
Outputs:
BandwidthPackageId:
Description: The ID of the Internet Shared Bandwidth instance.
Value:
Fn::GetAtt:
- CommonBandwidthPackage
- BandwidthPackageId{
"ROSTemplateFormatVersion": "2015-09-01",
"Parameters": {
},
"Resources": {
"CommonBandwidthPackage": {
"Type": "ALIYUN::VPC::CommonBandwidthPackage",
"Properties": {
"Description": "Test",
"Name": "test-dsa",
"Bandwidth": 5,
"InternetChargeType": "PayByBandwidth"
}
}
},
"Outputs": {
"BandwidthPackageId": {
"Description": "The ID of the Internet Shared Bandwidth instance.",
"Value": {
"Fn::GetAtt": [
"CommonBandwidthPackage",
"BandwidthPackageId"
]
}
}
}
}{
"ROSTemplateFormatVersion": "2015-09-01",
"Parameters": {
},
"Resources": {
"CommonBandwidthPackage": {
"Type": "ALIYUN::VPC::CommonBandwidthPackage",
"Properties": {
"Description": "Test",
"Name": "test-dsa",
"Bandwidth": 5,
"InternetChargeType": "PayByBandwidth"
}
}
},
"Outputs": {
"BandwidthPackageId": {
"Description": "The ID of the Internet Shared Bandwidth instance.",
"Value": {
"Fn::GetAtt": [
"CommonBandwidthPackage",
"BandwidthPackageId"
]
}
}
}
}