Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GA ILB global access #1862

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .changelog/3253.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```release-note:enhancement
compute: Added `allow_global_access` for to `google_compute_forwarding_rule` resource.
```
12 changes: 6 additions & 6 deletions google-beta/resource_compute_forwarding_rule_generated_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,12 +33,17 @@ func TestAccComputeForwardingRule_forwardingRuleGlobalInternallbExample(t *testi

resource.Test(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t) },
Providers: testAccProvidersOiCS,
Providers: testAccProviders,
CheckDestroy: testAccCheckComputeForwardingRuleDestroy,
Steps: []resource.TestStep{
{
Config: testAccComputeForwardingRule_forwardingRuleGlobalInternallbExample(context),
},
{
ResourceName: "google_compute_forwarding_rule.default",
ImportState: true,
ImportStateVerify: true,
},
},
})
}
Expand All @@ -47,7 +52,6 @@ func testAccComputeForwardingRule_forwardingRuleGlobalInternallbExample(context
return Nprintf(`
// Forwarding rule for Internal Load Balancing
resource "google_compute_forwarding_rule" "default" {
provider = "google-beta"
name = "tf-test-website-forwarding-rule%{random_suffix}"
region = "us-central1"
load_balancing_scheme = "INTERNAL"
Expand All @@ -58,13 +62,11 @@ resource "google_compute_forwarding_rule" "default" {
subnetwork = "${google_compute_subnetwork.default.name}"
}
resource "google_compute_region_backend_service" "backend" {
provider = "google-beta"
name = "tf-test-website-backend%{random_suffix}"
region = "us-central1"
health_checks = ["${google_compute_health_check.hc.self_link}"]
}
resource "google_compute_health_check" "hc" {
provider = "google-beta"
name = "check-tf-test-website-backend%{random_suffix}"
check_interval_sec = 1
timeout_sec = 1
Expand All @@ -73,12 +75,10 @@ resource "google_compute_health_check" "hc" {
}
}
resource "google_compute_network" "default" {
provider = "google-beta"
name = "tf-test-website-net%{random_suffix}"
auto_create_subnetworks = false
}
resource "google_compute_subnetwork" "default" {
provider = "google-beta"
name = "tf-test-website-net%{random_suffix}"
ip_cidr_range = "10.0.0.0/16"
region = "us-central1"
Expand Down
7 changes: 1 addition & 6 deletions website/docs/r/compute_forwarding_rule.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,6 @@ To get more information about ForwardingRule, see:
```hcl
// Forwarding rule for Internal Load Balancing
resource "google_compute_forwarding_rule" "default" {
provider = "google-beta"
name = "website-forwarding-rule"
region = "us-central1"
load_balancing_scheme = "INTERNAL"
Expand All @@ -55,13 +54,11 @@ resource "google_compute_forwarding_rule" "default" {
subnetwork = "${google_compute_subnetwork.default.name}"
}
resource "google_compute_region_backend_service" "backend" {
provider = "google-beta"
name = "website-backend"
region = "us-central1"
health_checks = ["${google_compute_health_check.hc.self_link}"]
}
resource "google_compute_health_check" "hc" {
provider = "google-beta"
name = "check-website-backend"
check_interval_sec = 1
timeout_sec = 1
Expand All @@ -70,12 +67,10 @@ resource "google_compute_health_check" "hc" {
}
}
resource "google_compute_network" "default" {
provider = "google-beta"
name = "website-net"
auto_create_subnetworks = false
}
resource "google_compute_subnetwork" "default" {
provider = "google-beta"
name = "website-net"
ip_cidr_range = "10.0.0.0/16"
region = "us-central1"
Expand Down Expand Up @@ -480,7 +475,7 @@ The following arguments are supported:
object.

* `allow_global_access` -
(Optional, [Beta](https://terraform.io/docs/providers/google/guides/provider_versions.html))
(Optional)
If true, clients can access ILB from all regions.
Otherwise only allows from the local region the ILB is located at.

Expand Down