github.com/andresvia/terraform@v0.6.15-0.20160412045437-d51c75946785/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 ``` 16 resource "cloudstack_port_forward" "default" { 17 ip_address = "192.168.0.1" 18 19 forward { 20 protocol = "tcp" 21 private_port = 80 22 public_port = 8080 23 virtual_machine = "server-1" 24 } 25 } 26 ``` 27 28 ## Argument Reference 29 30 The following arguments are supported: 31 32 * `ip_address` - (Required) The IP address for which to create the port forwards. 33 Changing this forces a new resource to be created. 34 35 * `ipaddress` - (Required, Deprecated) The IP address for which to create the port 36 forwards. Changing this forces a new resource to be created. 37 38 * `managed` - (Optional) USE WITH CAUTION! If enabled all the port forwards for 39 this IP address will be managed by this resource. This means it will delete 40 all port forwards that are not in your config! (defaults false) 41 42 * `forward` - (Required) Can be specified multiple times. Each forward block supports 43 fields documented below. 44 45 The `forward` block supports: 46 47 * `protocol` - (Required) The name of the protocol to allow. Valid options are: 48 `tcp` and `udp`. 49 50 * `private_port` - (Required) The private port to forward to. 51 52 * `public_port` - (Required) The public port to forward from. 53 54 * `virtual_machine` - (Required) The name or ID of the virtual machine to forward to. 55 56 ## Attributes Reference 57 58 The following attributes are exported: 59 60 * `ip_address` - The IP address for which the port forwards are created.