github.com/simonswine/terraform@v0.9.0-beta2/website/source/docs/providers/google/r/compute_forwarding_rule.html.markdown (about)

     1  ---
     2  layout: "google"
     3  page_title: "Google: google_compute_forwarding_rule"
     4  sidebar_current: "docs-google-compute-forwarding-rule"
     5  description: |-
     6    Manages a Target Pool within GCE.
     7  ---
     8  
     9  # google\_compute\_forwarding\_rule
    10  
    11  Manages a Forwarding Rule within GCE. This binds an ip and port range to a target pool. For more
    12  information see [the official
    13  documentation](https://cloud.google.com/compute/docs/load-balancing/network/forwarding-rules) and
    14  [API](https://cloud.google.com/compute/docs/reference/latest/forwardingRules).
    15  
    16  ## Example Usage
    17  
    18  ```tf
    19  resource "google_compute_forwarding_rule" "default" {
    20    name       = "test"
    21    target     = "${google_compute_target_pool.default.self_link}"
    22    port_range = "80"
    23  }
    24  ```
    25  
    26  ## Argument Reference
    27  
    28  The following arguments are supported:
    29  
    30  * `name` - (Required) A unique name for the resource, required by GCE. Changing
    31      this forces a new resource to be created.
    32  
    33  - - -
    34  
    35  * `backend_service` - (Optional) BackendService resource to receive the
    36      matched traffic. Only used for internal load balancing.
    37  
    38  * `description` - (Optional) Textual description field.
    39  
    40  * `ip_address` - (Optional) The static IP. (if not set, an ephemeral IP is
    41      used).
    42  
    43  * `ip_protocol` - (Optional) The IP protocol to route, one of "TCP" "UDP" "AH"
    44      "ESP" or "SCTP" for external load balancing, "TCP" or "UDP" for internal
    45      (default "TCP").
    46  
    47  * `load_balancing_scheme` - (Optional) Type of load balancing to use. Can be
    48      set to "INTERNAL" or "EXTERNAL" (default "EXTERNAL").
    49  
    50  * `network` - (Optional) Network that the load balanced IP should belong to.
    51      Only used for internal load balancing. If it is not provided, the default
    52      network is used.
    53  
    54  * `port_range` - (Optional) A range e.g. "1024-2048" or a single port "1024"
    55      (defaults to all ports!). Only used for external load balancing.
    56  
    57  * `ports` - (Optional) A list of ports to use for internal load balancing
    58      (defaults to all ports).
    59  
    60  * `project` - (Optional) The project in which the resource belongs. If it
    61      is not provided, the provider project is used.
    62  
    63  * `region` - (Optional) The Region in which the created address should reside.
    64      If it is not provided, the provider region is used.
    65  
    66  * `subnetwork` - (Optional) Subnetwork that the load balanced IP should belong
    67      to. Only used for internal load balancing. Must be specified if the network
    68      is in custom subnet mode.
    69  
    70  * `target` - (Optional) URL of target pool. Required for external load
    71      balancing.
    72  
    73  ## Attributes Reference
    74  
    75  In addition to the arguments listed above, the following computed attributes are
    76  exported:
    77  
    78  * `self_link` - The URI of the created resource.