@@ -7114,7 +7114,7 @@ func TestAccContainerCluster_withCidrBlockWithoutPrivateEndpointSubnetwork(t *te
7114
7114
CheckDestroy : testAccCheckContainerClusterDestroyProducer (t ),
7115
7115
Steps : []resource.TestStep {
7116
7116
{
7117
- Config : testAccContainerCluster_withCidrBlockWithoutPrivateEndpointSubnetwork (containerNetName , clusterName , "us-central1-a" ),
7117
+ Config : testAccContainerCluster_withCidrBlockWithoutPrivateEndpointSubnetwork (containerNetName , clusterName ),
7118
7118
},
7119
7119
{
7120
7120
ResourceName : "google_container_cluster.with_private_flexible_cluster" ,
@@ -7126,8 +7126,12 @@ func TestAccContainerCluster_withCidrBlockWithoutPrivateEndpointSubnetwork(t *te
7126
7126
})
7127
7127
}
7128
7128
7129
- func testAccContainerCluster_withCidrBlockWithoutPrivateEndpointSubnetwork (containerNetName , clusterName , location string ) string {
7129
+ func testAccContainerCluster_withCidrBlockWithoutPrivateEndpointSubnetwork (containerNetName , clusterName string ) string {
7130
7130
return fmt .Sprintf (`
7131
+ data "google_container_engine_versions" "uscentral1a" {
7132
+ location = "us-central1-a"
7133
+ }
7134
+
7131
7135
resource "google_compute_network" "container_network" {
7132
7136
name = "%s"
7133
7137
auto_create_subnetworks = false
@@ -7141,8 +7145,8 @@ resource "google_compute_subnetwork" "container_subnetwork" {
7141
7145
7142
7146
resource "google_container_cluster" "with_private_flexible_cluster" {
7143
7147
name = "%s"
7144
- location = "%s "
7145
- min_master_version = "1.29"
7148
+ location = "us-central1-a "
7149
+ min_master_version = data.google_container_engine_versions.uscentral1a.release_channel_latest_version["STABLE"]
7146
7150
initial_node_count = 1
7147
7151
7148
7152
networking_mode = "VPC_NATIVE"
@@ -7155,7 +7159,7 @@ resource "google_container_cluster" "with_private_flexible_cluster" {
7155
7159
}
7156
7160
deletion_protection = false
7157
7161
}
7158
- ` , containerNetName , clusterName , location )
7162
+ ` , containerNetName , clusterName )
7159
7163
}
7160
7164
7161
7165
func TestAccContainerCluster_withEnablePrivateEndpointToggle (t * testing.T ) {
0 commit comments