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

     1  ---
     2  layout: "cloudstack"
     3  page_title: "CloudStack: cloudstack_port_forward"
     4  sidebar_current: "docs-cloudstack-resource-port-forward"
     5  description: |-
     6    Creates port forwards.
     7  ---
     8  
     9  # cloudstack_port_forward
    10  
    11  Creates port forwards.
    12  
    13  ## Example Usage
    14  
    15  ```hcl
    16  resource "cloudstack_port_forward" "default" {
    17    ip_address_id = "30b21801-d4b3-4174-852b-0c0f30bdbbfb"
    18  
    19    forward {
    20      protocol           = "tcp"
    21      private_port       = 80
    22      public_port        = 8080
    23      virtual_machine_id = "f8141e2f-4e7e-4c63-9362-986c908b7ea7"
    24    }
    25  }
    26  ```
    27  
    28  ## Argument Reference
    29  
    30  The following arguments are supported:
    31  
    32  * `ip_address_id` - (Required) The IP address ID for which to create the port
    33      forwards. Changing this forces a new resource to be created.
    34  
    35  * `managed` - (Optional) USE WITH CAUTION! If enabled all the port forwards for
    36      this IP address will be managed by this resource. This means it will delete
    37      all port forwards that are not in your config! (defaults false)
    38  
    39  * `forward` - (Required) Can be specified multiple times. Each forward block supports
    40      fields documented below.
    41  
    42  The `forward` block supports:
    43  
    44  * `protocol` - (Required) The name of the protocol to allow. Valid options are:
    45      `tcp` and `udp`.
    46  
    47  * `private_port` - (Required) The private port to forward to.
    48  
    49  * `public_port` - (Required) The public port to forward from.
    50  
    51  * `virtual_machine_id` - (Required) The ID of the virtual machine to forward to.
    52  
    53  * `vm_guest_ip` - (Optional) The virtual machine IP address for the port
    54      forwarding rule (useful when the virtual machine has secondairy NICs
    55      or IP addresses).
    56  
    57  ## Attributes Reference
    58  
    59  The following attributes are exported:
    60  
    61  * `id` - The ID of the IP address for which the port forwards are created.
    62  * `vm_guest_ip` - The IP address of the virtual machine that is used
    63      for the port forwarding rule.