mirror of
https://github.com/letic/terraform-provider-google.git
synced 2024-06-29 06:42:36 +00:00
Fix google_container_cluster docs about fields gone GA (#2597)
<!-- This change is generated by MagicModules. --> /cc @rileykarson
This commit is contained in:
parent
3a287fa3a3
commit
c6f02a1e88
|
@ -34,20 +34,24 @@ func resourceBigtableInstance() *schema.Resource {
|
|||
"cluster_id": {
|
||||
Type: schema.TypeString,
|
||||
Required: true,
|
||||
ForceNew: true,
|
||||
},
|
||||
"zone": {
|
||||
Type: schema.TypeString,
|
||||
Required: true,
|
||||
ForceNew: true,
|
||||
},
|
||||
"num_nodes": {
|
||||
Type: schema.TypeInt,
|
||||
Optional: true,
|
||||
ForceNew: true,
|
||||
ValidateFunc: validation.IntAtLeast(3),
|
||||
},
|
||||
"storage_type": {
|
||||
Type: schema.TypeString,
|
||||
Optional: true,
|
||||
Default: "SSD",
|
||||
ForceNew: true,
|
||||
ValidateFunc: validation.StringInSlice([]string{"SSD", "HDD"}, false),
|
||||
},
|
||||
},
|
||||
|
|
|
@ -21,7 +21,14 @@ func TestAccBigtableInstance_basic(t *testing.T) {
|
|||
CheckDestroy: testAccCheckBigtableInstanceDestroy,
|
||||
Steps: []resource.TestStep{
|
||||
{
|
||||
Config: testAccBigtableInstance(instanceName),
|
||||
Config: testAccBigtableInstance(instanceName, 3),
|
||||
Check: resource.ComposeTestCheckFunc(
|
||||
testAccBigtableInstanceExists(
|
||||
"google_bigtable_instance.instance"),
|
||||
),
|
||||
},
|
||||
{
|
||||
Config: testAccBigtableInstance(instanceName, 4),
|
||||
Check: resource.ComposeTestCheckFunc(
|
||||
testAccBigtableInstanceExists(
|
||||
"google_bigtable_instance.instance"),
|
||||
|
@ -125,18 +132,18 @@ func testAccBigtableInstanceExists(n string) resource.TestCheckFunc {
|
|||
}
|
||||
}
|
||||
|
||||
func testAccBigtableInstance(instanceName string) string {
|
||||
func testAccBigtableInstance(instanceName string, numNodes int) string {
|
||||
return fmt.Sprintf(`
|
||||
resource "google_bigtable_instance" "instance" {
|
||||
name = "%s"
|
||||
cluster {
|
||||
cluster_id = "%s"
|
||||
zone = "us-central1-b"
|
||||
num_nodes = 3
|
||||
num_nodes = %d
|
||||
storage_type = "HDD"
|
||||
}
|
||||
}
|
||||
`, instanceName, instanceName)
|
||||
`, instanceName, instanceName, numNodes)
|
||||
}
|
||||
|
||||
func testAccBigtableInstance_cluster(instanceName string) string {
|
||||
|
|
|
@ -75,7 +75,7 @@ output "cluster_ca_certificate" {
|
|||
in `initial_node_count` should be created in. Only one of `zone` and `region`
|
||||
may be set. If neither zone nor region are set, the provider zone is used.
|
||||
|
||||
* `region` (Optional, [Beta](https://terraform.io/docs/providers/google/provider_versions.html))
|
||||
* `region` (Optional)
|
||||
The region to create the cluster in, for
|
||||
[Regional Clusters](https://cloud.google.com/kubernetes-engine/docs/concepts/multi-zone-and-regional-clusters#regional).
|
||||
In a Regional Cluster, the number of nodes specified in `initial_node_count` is
|
||||
|
@ -182,7 +182,7 @@ to the datasource. A `region` can have a different set of supported versions tha
|
|||
[PodSecurityPolicy](https://cloud.google.com/kubernetes-engine/docs/how-to/pod-security-policies) feature.
|
||||
Structure is documented below.
|
||||
|
||||
* `private_cluster_config` - (Optional, [Beta](https://terraform.io/docs/providers/google/provider_versions.html)) A set of options for creating
|
||||
* `private_cluster_config` - (Optional) A set of options for creating
|
||||
a private cluster. Structure is documented below.
|
||||
|
||||
* `project` - (Optional) The ID of the project in which the resource belongs. If it
|
||||
|
@ -473,8 +473,7 @@ exported:
|
|||
|
||||
## Import
|
||||
|
||||
GKE clusters can be imported using the `project` , `zone` or `region` (`region`
|
||||
is deprecated, see above), and `name`. If the project is omitted, the default
|
||||
GKE clusters can be imported using the `project` , `zone` or `region`, and `name`. If the project is omitted, the default
|
||||
provider value will be used. Examples:
|
||||
|
||||
```
|
||||
|
|
Loading…
Reference in New Issue
Block a user