ALIYUN::KMS::NetworkRule类型用于创建一条网络控制规则。
语法
{
"Type": "ALIYUN::KMS::NetworkRule",
"Properties": {
"NetworkRuleName": String,
"Description": String,
"SourcePrivateIp": List
}
}
属性
属性名称 | 类型 | 必须 | 允许更新 | 描述 | 约束 |
NetworkRuleName | String | 是 | 否 | 网络控制规则名称。 | 无 |
Description | String | 否 | 是 | 描述信息。 | 无 |
SourcePrivateIp | List | 否 | 是 | 私网IP地址或者私网网段列表。 | 最多支持800个私网IP地址或者私网网段。 |
返回值
Fn::GetAtt
Description:描述信息。
SourcePrivateIp:私网IP地址或者私网网段列表。
示例
ROSTemplateFormatVersion: '2015-09-01'
Parameters:
SourcePrivateIp:
AssociationPropertyMetadata:
Parameter:
Type: String
Description:
en: CIDR format IP.
Required: false
AssociationProperty: List[Parameter]
Type: Json
Description:
en: VPC network whitelist, The private IP address or private CIDR block, Supports binding up to 800 CIDR blocks or IP addresses.
Required: false
MinLength: 1
MaxLength: 800
NetworkRuleName:
Type: String
Description:
en: The name of the access control rule.
Required: true
Resources:
ExtensionResource:
Type: ALIYUN::KMS::NetworkRule
Properties:
SourcePrivateIp:
Ref: SourcePrivateIp
NetworkRuleName:
Ref: NetworkRuleName
Outputs:
Description:
Description: Description.
Value:
Fn::GetAtt:
- ExtensionResource
- Description
SourcePrivateIp:
Description: VPC network whitelist.
Value:
Fn::GetAtt:
- ExtensionResource
- SourcePrivateIp
{
"ROSTemplateFormatVersion": "2015-09-01",
"Parameters": {
"SourcePrivateIp": {
"AssociationPropertyMetadata": {
"Parameter": {
"Type": "String",
"Description": {
"en": "CIDR format IP."
},
"Required": false
}
},
"AssociationProperty": "List[Parameter]",
"Type": "Json",
"Description": {
"en": "VPC network whitelist, The private IP address or private CIDR block, Supports binding up to 800 CIDR blocks or IP addresses."
},
"Required": false,
"MinLength": 1,
"MaxLength": 800
},
"NetworkRuleName": {
"Type": "String",
"Description": {
"en": "The name of the access control rule."
},
"Required": true
}
},
"Resources": {
"ExtensionResource": {
"Type": "ALIYUN::KMS::NetworkRule",
"Properties": {
"SourcePrivateIp": {
"Ref": "SourcePrivateIp"
},
"NetworkRuleName": {
"Ref": "NetworkRuleName"
}
}
}
},
"Outputs": {
"Description": {
"Description": "Description.",
"Value": {
"Fn::GetAtt": [
"ExtensionResource",
"Description"
]
}
},
"SourcePrivateIp": {
"Description": "VPC network whitelist.",
"Value": {
"Fn::GetAtt": [
"ExtensionResource",
"SourcePrivateIp"
]
}
}
}
}
文档内容是否对您有帮助?