ALIYUN::SLB::AccessControl is used to create an access control list (ACL).

Syntax

{
  "Type": "ALIYUN::SLB::AccessControl",
  "Properties": {
    "AddressIPVersion": String,
    "AclName": String,
    "AclEntrys": List,
    "Tags": List,
    "ResourceGroupId": String
  }
}

Properties

PropertyTypeRequiredEditableDescriptionConstraint
AddressIPVersionStringNoNoThe Internet Protocol version. Valid values:
  • ipv4
  • ipv6
AclNameStringYesYesThe name of the ACL. None.
ResourceGroupIdStringNoYesThe ID of the resource group to which the ACL belongs. None.
AclEntrysListNoNoThe list of ACL entries. The list can contain a maximum of 50 ACL entries.

For more information, see AclEntrys properties.

TagsListNoYesThe tags. You can add up to 20 tags.

For more information, see Tags property.

AclEntrys syntax

"AclEntrys": [
  {
    "comment": String,
    "entry": String
  }
]

AclEntrys properties

PropertyTypeRequiredEditableDescriptionConstraint
commentStringNoNoThe description of the ACL entry. None.
entryStringYesNoThe IP address or CIDR block. None.

Tags syntax

"Tags": [
  {
    "Key": String,
    "Value": String
  }
]  

Tags property

PropertyTypeRequiredEditableDescriptionConstraint
KeyStringYesNoThe key of the tag. The tag key must be 1 to 128 characters in length, and cannot contain http:// or https://. The tag key cannot start with acs: or aliyun.
ValueStringNoNoThe value of the tag. The tag value must be 0 to 128 characters in length, and cannot contain http:// or https://. The tag value cannot start with acs: or aliyun.

Return values

Fn::GetAtt

AclId: the ID of the ACL.

Examples

  • YAMLformat

    ROSTemplateFormatVersion: '2015-09-01'
    Parameters: {}
    Resources:
      AccessControl:
        Type: ALIYUN::SLB::AccessControl
        Properties:
          AddressIPVersion: ipv4
          AclName:
            Ref: TestAcl
          AclEntrys:
            - entry: 0.0.0.0
    Outputs:
      AclId:
        Description: The ID of the access control list.
        Value:
          Fn::GetAtt:
            - AccessControl
            - AclId
  • JSONformat

    {
      "ROSTemplateFormatVersion": "2015-09-01",
      "Parameters": {
      },
      "Resources": {
        "AccessControl": {
          "Type": "ALIYUN::SLB::AccessControl",
          "Properties": {
            "AddressIPVersion": "ipv4",
            "AclName": {
              "Ref": "TestAcl"
            },
            "AclEntrys": [
              {
                "entry": "0.0.0.0"
              }
            ]
          }
        }
      },
      "Outputs": {
        "AclId": {
          "Description": "The ID of the access control list.",
          "Value": {
            "Fn::GetAtt": [
              "AccessControl",
              "AclId"
            ]
          }
        }
      }
    }

To view more examples, visit AccessControl.json and AccessControl.yml.