Skip to content

Commit

Permalink
google_vpc_access_connector missing GA args (#6718) (#4805)
Browse files Browse the repository at this point in the history
Signed-off-by: Modular Magician <magic-modules@google.com>

Signed-off-by: Modular Magician <magic-modules@google.com>
  • Loading branch information
modular-magician authored Oct 19, 2022
1 parent 951c0c8 commit bcfdd96
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 17 deletions.
3 changes: 3 additions & 0 deletions .changelog/6718.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```release-note:enhancement
vpcaccess - promoted `machine_type`, `min_instances`, `max_instances`, and `subnet` in `google_vpc_access_connector` to GA
```
5 changes: 1 addition & 4 deletions google-beta/resource_vpc_access_connector_generated_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ func TestAccVPCAccessConnector_vpcAccessConnectorSharedVPCExample(t *testing.T)

vcrTest(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t) },
Providers: testAccProvidersOiCS,
Providers: testAccProviders,
CheckDestroy: testAccCheckVPCAccessConnectorDestroyProducer(t),
Steps: []resource.TestStep{
{
Expand All @@ -86,7 +86,6 @@ func TestAccVPCAccessConnector_vpcAccessConnectorSharedVPCExample(t *testing.T)
func testAccVPCAccessConnector_vpcAccessConnectorSharedVPCExample(context map[string]interface{}) string {
return Nprintf(`
resource "google_vpc_access_connector" "connector" {
provider = google-beta
name = "tf-test-vpc-con%{random_suffix}"
subnet {
name = google_compute_subnetwork.custom_test.name
Expand All @@ -95,15 +94,13 @@ resource "google_vpc_access_connector" "connector" {
}
resource "google_compute_subnetwork" "custom_test" {
provider = google-beta
name = "tf-test-vpc-con%{random_suffix}"
ip_cidr_range = "10.2.0.0/28"
region = "us-central1"
network = google_compute_network.custom_test.id
}
resource "google_compute_network" "custom_test" {
provider = google-beta
name = "tf-test-vpc-con%{random_suffix}"
auto_create_subnetworks = false
}
Expand Down
5 changes: 1 addition & 4 deletions google-beta/resource_vpc_access_connector_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ func TestAccVPCAccessConnector_vpcAccessConnectorThroughput(t *testing.T) {

vcrTest(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t) },
Providers: testAccProvidersOiCS,
Providers: testAccProviders,
CheckDestroy: testAccCheckVPCAccessConnectorDestroyProducer(t),
Steps: []resource.TestStep{
{
Expand All @@ -33,7 +33,6 @@ func TestAccVPCAccessConnector_vpcAccessConnectorThroughput(t *testing.T) {
func testAccVPCAccessConnector_vpcAccessConnectorThroughput(context map[string]interface{}) string {
return Nprintf(`
resource "google_vpc_access_connector" "connector" {
provider = google-beta
name = "tf-test-vpc-con%{random_suffix}"
subnet {
name = google_compute_subnetwork.custom_test.name
Expand All @@ -45,15 +44,13 @@ resource "google_vpc_access_connector" "connector" {
}
resource "google_compute_subnetwork" "custom_test" {
provider = google-beta
name = "tf-test-vpc-con%{random_suffix}"
ip_cidr_range = "10.2.0.0/28"
region = "us-central1"
network = google_compute_network.custom_test.id
}
resource "google_compute_network" "custom_test" {
provider = google-beta
name = "tf-test-vpc-con%{random_suffix}"
auto_create_subnetworks = false
}
Expand Down
15 changes: 6 additions & 9 deletions website/docs/r/vpc_access_connector.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,6 @@ resource "google_vpc_access_connector" "connector" {

```hcl
resource "google_vpc_access_connector" "connector" {
provider = google-beta
name = "vpc-con"
subnet {
name = google_compute_subnetwork.custom_test.name
Expand All @@ -63,15 +62,13 @@ resource "google_vpc_access_connector" "connector" {
}
resource "google_compute_subnetwork" "custom_test" {
provider = google-beta
name = "vpc-con"
ip_cidr_range = "10.2.0.0/28"
region = "us-central1"
network = google_compute_network.custom_test.id
}
resource "google_compute_network" "custom_test" {
provider = google-beta
name = "vpc-con"
auto_create_subnetworks = false
}
Expand Down Expand Up @@ -99,27 +96,27 @@ The following arguments are supported:
The range of internal addresses that follows RFC 4632 notation. Example: `10.132.0.0/28`.

* `machine_type` -
(Optional, [Beta](https://terraform.io/docs/providers/google/guides/provider_versions.html))
(Optional)
Machine type of VM Instance underlying connector. Default is e2-micro

* `min_throughput` -
(Optional)
Minimum throughput of the connector in Mbps. Default and min is 200.

* `min_instances` -
(Optional, [Beta](https://terraform.io/docs/providers/google/guides/provider_versions.html))
(Optional)
Minimum value of instances in autoscaling group underlying the connector.

* `max_instances` -
(Optional, [Beta](https://terraform.io/docs/providers/google/guides/provider_versions.html))
(Optional)
Maximum value of instances in autoscaling group underlying the connector.

* `max_throughput` -
(Optional)
Maximum throughput of the connector in Mbps, must be greater than `min_throughput`. Default is 300.

* `subnet` -
(Optional, [Beta](https://terraform.io/docs/providers/google/guides/provider_versions.html))
(Optional)
The subnet in which to house the connector
Structure is [documented below](#nested_subnet).

Expand All @@ -134,12 +131,12 @@ The following arguments are supported:
<a name="nested_subnet"></a>The `subnet` block supports:

* `name` -
(Optional, [Beta](https://terraform.io/docs/providers/google/guides/provider_versions.html))
(Optional)
Subnet name (relative, not fully qualified). E.g. if the full subnet selfLink is
https://compute.googleapis.com/compute/v1/projects/{project}/regions/{region}/subnetworks/{subnetName} the correct input for this field would be {subnetName}"

* `project_id` -
(Optional, [Beta](https://terraform.io/docs/providers/google/guides/provider_versions.html))
(Optional)
Project in which the subnet exists. If not set, this project is assumed to be the project for which the connector create request was issued.

## Attributes Reference
Expand Down

0 comments on commit bcfdd96

Please sign in to comment.