ALIYUN::CR::InstanceEndpointAclPolicy类型用于为公网实例访问入口创建白名单策略。
语法
{
  "Type": "ALIYUN::CR::InstanceEndpointAclPolicy",
  "Properties": {
    "AutoEnableType": String,
    "Comment": String,
    "Entry": String,
    "InstanceId": String,
    "ModuleName": String,
    "EndpointType": String,
    "RegionId": String
  }
}属性
| 属性名称 | 类型 | 必须 | 允许更新 | 描述 | 约束 | 
| AutoEnableType | String | 否 | 否 | 是否自动启用端点的类型。 | 取值: 
 | 
| Comment | String | 否 | 否 | 说明。 | 无 | 
| Entry | String | 是 | 否 | 允许访问的IP网段,例如192.168.1.1/32。 | 无 | 
| InstanceId | String | 是 | 否 | 实例ID。 | 无 | 
| ModuleName | String | 否 | 否 | 需要设置访问策略的模块。 | 取值: 
 | 
| EndpointType | String | 否 | 否 | 访问入口类型。 | 取值: internet(公网)。 | 
| RegionId | String | 否 | 否 | 地域ID。 | 默认为资源栈地域ID。 | 
返回值
Fn::GetAtt
- Entry:允许访问的IP网段。 
- InstanceId:实例ID。 
示例
{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "Entry": {
      "Type": "String",
      "Description": "The IP address range that is allowed to access the instance.",
      "Default": "192.168.1.1/32"
    },
    "InstanceId": {
      "Type": "String",
      "Description": "The ID of the instance."
    }
  },
  "Resources": {
    "InstanceEndpointAclPolicy": {
      "Type": "ALIYUN::CR::InstanceEndpointAclPolicy",
      "Properties": {
        "Entry": {
          "Ref": "Entry"
        },
        "InstanceId": {
          "Ref": "InstanceId"
        }
      }
    }
  },
  "Outputs": {
    "Entry": {
      "Description": "The IP address range that is allowed to access the instance.",
      "Value": {
        "Fn::GetAtt": [
          "InstanceEndpointAclPolicy",
          "Entry"
        ]
      }
    },
    "InstanceId": {
      "Description": "The ID of the instance.",
      "Value": {
        "Fn::GetAtt": [
          "InstanceEndpointAclPolicy",
          "InstanceId"
        ]
      }
    }
  }
}ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  Entry:
    Type: String
    Description: The IP address range that is allowed to access the instance.
    Default: 192.168.1.1/32
  InstanceId:
    Type: String
    Description: The ID of the instance.
Resources:
  InstanceEndpointAclPolicy:
    Type: 'ALIYUN::CR::InstanceEndpointAclPolicy'
    Properties:
      Entry:
        Ref: Entry
      InstanceId:
        Ref: InstanceId
Outputs:
  Entry:
    Description: The IP address range that is allowed to access the instance.
    Value:
      'Fn::GetAtt':
        - InstanceEndpointAclPolicy
        - Entry
  InstanceId:
    Description: The ID of the instance.
    Value:
      'Fn::GetAtt':
        - InstanceEndpointAclPolicy
        - InstanceId该文章对您有帮助吗?