github.com/nathanielks/terraform@v0.6.1-0.20170509030759-13e1a62319dc/website/source/docs/providers/cloudstack/r/network_acl_rule.html.markdown (about)

     1  ---
     2  layout: "cloudstack"
     3  page_title: "CloudStack: cloudstack_network_acl_rule"
     4  sidebar_current: "docs-cloudstack-resource-network-acl-rule"
     5  description: |-
     6    Creates network ACL rules for a given network ACL.
     7  ---
     8  
     9  # cloudstack_network_acl_rule
    10  
    11  Creates network ACL rules for a given network ACL.
    12  
    13  ## Example Usage
    14  
    15  ```hcl
    16  resource "cloudstack_network_acl_rule" "default" {
    17    acl_id = "f3843ce0-334c-4586-bbd3-0c2e2bc946c6"
    18  
    19    rule {
    20      action       = "allow"
    21      cidr_list    = ["10.0.0.0/8"]
    22      protocol     = "tcp"
    23      ports        = ["80", "1000-2000"]
    24      traffic_type = "ingress"
    25    }
    26  }
    27  ```
    28  
    29  ## Argument Reference
    30  
    31  The following arguments are supported:
    32  
    33  * `acl_id` - (Required) The network ACL ID for which to create the rules.
    34      Changing this forces a new resource to be created.
    35  
    36  * `managed` - (Optional) USE WITH CAUTION! If enabled all the firewall rules for
    37      this network ACL will be managed by this resource. This means it will delete
    38      all firewall rules that are not in your config! (defaults false)
    39  
    40  * `rule` - (Optional) Can be specified multiple times. Each rule block supports
    41      fields documented below. If `managed = false` at least one rule is required!
    42  
    43  * `project` - (Optional) The name or ID of the project to deploy this
    44      instance to. Changing this forces a new resource to be created.
    45  
    46  * `parallelism` (Optional) Specifies how much rules will be created or deleted
    47      concurrently. (defaults 2)
    48  
    49  The `rule` block supports:
    50  
    51  * `action` - (Optional) The action for the rule. Valid options are: `allow` and
    52      `deny` (defaults allow).
    53  
    54  * `cidr_list` - (Required) A CIDR list to allow access to the given ports.
    55  
    56  * `protocol` - (Required) The name of the protocol to allow. Valid options are:
    57      `tcp`, `udp`, `icmp`, `all` or a valid protocol number.
    58  
    59  * `icmp_type` - (Optional) The ICMP type to allow, or `-1` to allow `any`. This
    60      can only be specified if the protocol is ICMP. (defaults 0)
    61  
    62  * `icmp_code` - (Optional) The ICMP code to allow, or `-1` to allow `any`. This
    63      can only be specified if the protocol is ICMP. (defaults 0)
    64  
    65  * `ports` - (Optional) List of ports and/or port ranges to allow. This can only
    66      be specified if the protocol is TCP, UDP, ALL or a valid protocol number.
    67  
    68  * `traffic_type` - (Optional) The traffic type for the rule. Valid options are:
    69      `ingress` or `egress` (defaults ingress).
    70  
    71  ## Attributes Reference
    72  
    73  The following attributes are exported:
    74  
    75  * `id` - The ACL ID for which the rules are created.