mirror of
https://github.com/letic/terraform-provider-google.git
synced 2024-10-04 17:51:11 +00:00
provider/google: always set additional_zones on read
This commit is contained in:
parent
e0663f35b2
commit
562c25dba8
@ -442,15 +442,15 @@ func resourceContainerClusterRead(d *schema.ResourceData, meta interface{}) erro
|
|||||||
d.Set("name", cluster.Name)
|
d.Set("name", cluster.Name)
|
||||||
d.Set("zone", cluster.Zone)
|
d.Set("zone", cluster.Zone)
|
||||||
|
|
||||||
if len(cluster.Locations) > 1 {
|
|
||||||
locations := []string{}
|
locations := []string{}
|
||||||
|
if len(cluster.Locations) > 1 {
|
||||||
for _, location := range cluster.Locations {
|
for _, location := range cluster.Locations {
|
||||||
if location != cluster.Zone {
|
if location != cluster.Zone {
|
||||||
locations = append(locations, location)
|
locations = append(locations, location)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
d.Set("additional_zones", locations)
|
|
||||||
}
|
}
|
||||||
|
d.Set("additional_zones", locations)
|
||||||
|
|
||||||
d.Set("endpoint", cluster.Endpoint)
|
d.Set("endpoint", cluster.Endpoint)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user