ALIYUN::VPC::IpamPool类型用于创建IPAM地址池。
语法
{
"Type": "ALIYUN::VPC::IpamPool",
"Properties": {
"IpamScopeId": String,
"AllocationDefaultCidrMask": Integer,
"AllocationMinCidrMask": Integer,
"AutoImport": Boolean,
"AllocationMaxCidrMask": Integer,
"Ipv6Isp": String,
"IpamPoolName": String,
"IpVersion": String,
"IpamPoolDescription": String,
"PoolRegionId": String,
"ResourceGroupId": String,
"SourceIpamPoolId": String,
"Tags": List
}
}
属性
|
属性名称 |
类型 |
必须 |
允许更新 |
描述 |
约束 |
|
IpamScopeId |
String |
是 |
否 |
IPAM作用域ID。 |
无 |
|
AllocationDefaultCidrMask |
Integer |
否 |
是 |
默认分配的CIDR掩码。 |
无 |
|
AllocationMaxCidrMask |
Integer |
否 |
是 |
最大分配的CIDR掩码。 |
无 |
|
AllocationMinCidrMask |
Integer |
否 |
是 |
最小分配的CIDR掩码。 |
无 |
|
AutoImport |
Boolean |
否 |
是 |
是否自动导入IP地址管理池。 |
无 |
|
Ipv6Isp |
String |
否 |
否 |
IPAM地址池的IPv6运营商。 |
无 |
|
IpamPoolDescription |
String |
否 |
是 |
IPAM地址池的描述信息。 |
无 |
|
IpamPoolName |
String |
否 |
是 |
IPAM地址池名称。 |
无 |
|
IpVersion |
String |
否 |
否 |
IPAM地址池的IP版本。 |
取值:
|
|
PoolRegionId |
String |
否 |
否 |
IPAM地址池的生效地域。 |
无 |
|
ResourceGroupId |
String |
否 |
是 |
IPAM地址池的资源组ID。 |
无 |
|
SourceIpamPoolId |
String |
否 |
否 |
源IPAM地址池ID。 |
无 |
|
Tags |
List |
否 |
是 |
IPAM地址池绑定的自定义标签。 |
更多属性,请参考Tags属性。 |
Tags语法
"Tags": [
{
"Value": String,
"Key": String
}
]
Tags属性
|
属性名称 |
类型 |
必须 |
允许更新 |
描述 |
约束 |
|
Key |
String |
是 |
是 |
标签键。 |
无 |
|
Value |
String |
是 |
是 |
标签值。 |
无 |
返回值
Fn::GetAtt
IpamPoolId:IPAM地址池ID。
示例
ROSTemplateFormatVersion: '2015-09-01'
Parameters:
IpamPoolName:
Type: String
Description:
en: The name of the IPAM pool.
Required: false
IpVersion:
Type: String
Description:
en: 'The IP version of the IPAM pool. Valid values: IPv4, IPv6.'
Required: false
AllocationDefaultCidrMask:
Type: Number
Description:
en: The default CIDR mask for allocation.
Required: false
MinValue: 0
MaxValue: 128
IpamScopeId:
Type: String
Description:
en: The ID of the IPAM scope. This parameter is required.
Required: true
Resources:
IpamPool:
Type: ALIYUN::VPC::IpamPool
Properties:
IpamPoolName:
Ref: IpamPoolName
IpVersion:
Ref: IpVersion
AllocationDefaultCidrMask:
Ref: AllocationDefaultCidrMask
IpamScopeId:
Ref: IpamScopeId
Outputs:
IpamPoolId:
Description: The ID of the IPAM pool.
Value:
Fn::GetAtt:
- IpamPool
- IpamPoolId
{
"ROSTemplateFormatVersion": "2015-09-01",
"Parameters": {
"IpamPoolName": {
"Type": "String",
"Description": {
"en": "The name of the IPAM pool."
},
"Required": false
},
"IpVersion": {
"Type": "String",
"Description": {
"en": "The IP version of the IPAM pool. Valid values: IPv4, IPv6."
},
"Required": false
},
"AllocationDefaultCidrMask": {
"Type": "Number",
"Description": {
"en": "The default CIDR mask for allocation."
},
"Required": false,
"MinValue": 0,
"MaxValue": 128
},
"IpamScopeId": {
"Type": "String",
"Description": {
"en": "The ID of the IPAM scope. This parameter is required."
},
"Required": true
}
},
"Resources": {
"IpamPool": {
"Type": "ALIYUN::VPC::IpamPool",
"Properties": {
"IpamPoolName": {
"Ref": "IpamPoolName"
},
"IpVersion": {
"Ref": "IpVersion"
},
"AllocationDefaultCidrMask": {
"Ref": "AllocationDefaultCidrMask"
},
"IpamScopeId": {
"Ref": "IpamScopeId"
}
}
}
},
"Outputs": {
"IpamPoolId": {
"Description": "The ID of the IPAM pool.",
"Value": {
"Fn::GetAtt": [
"IpamPool",
"IpamPoolId"
]
}
}
}
}
该文章对您有帮助吗?