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

fixed scenario where region_instance_group_manager would not start update #5582

Conversation

ScottSuarez
Copy link
Contributor

closes hashicorp/terraform-provider-google#10648 and hashicorp/terraform-provider-google#10792

duplicate pr of #5506 just against RIGM

Release Note Template for Downstream PRs (will be copied)

compute: fixed scenario where `region_instance_group_manager` would not start update if `wait_for_instances` was set and initial status was not `STABLE`

Zeya Zhang and others added 5 commits December 10, 2021 14:21
For autopilot clusters, the networking is pre-configured. With container
gen-client, we want to send `IPAllocationPolicy.UseIpAliases` and `IPAllocationPolicy.UseRoutes` as false,
so that the service can pick the default IP allocation mode [1].

Only when the `networkingMode` is specifically set to "ROUTES",
`IPAllocationPolicy.UseRoutes` is passed with true.

This change fixes the following error when apply an autopilot cluster

```
resource "google_container_cluster" "tf-cluster" {
  name     = "tf-cluster"
  location = "europe-west1"
  project = "my-project"

  enable_autopilot = "true"
  release_channel {
    channel = "REGULAR"
  }
  min_master_version = "1.21.5-gke.1302"
}
```

```
zgoogle_container_cluster.tf-cluster: Creating...

Error: googleapi: Error 400: Max pods constraint on node pools for Autopilot clusters should be 32., badRequest

  on container_cluster.tf line 1, in resource "google_container_cluster" "tf-cluster":
   1: resource "google_container_cluster" "tf-cluster" {

```
@modular-magician
Copy link
Collaborator

Hi! I'm the modular magician. Your PR generated some diffs in downstreams - here they are.

Diff report:

Terraform GA: Diff ( 2 files changed, 22 insertions(+), 29 deletions(-))
Terraform Beta: Diff ( 2 files changed, 18 insertions(+), 25 deletions(-))

@rileykarson
Copy link
Member

What's up w/ the PR title and history?

@ScottSuarez ScottSuarez changed the title Make container cluster work for both routes-based and autopilot clusters fixed scenario where region_instance_group_manager would not start update Dec 28, 2021
@ScottSuarez
Copy link
Contributor Author

ooops, yes I branched this from another change I was working on and had to go about scrubbing that from the branch.

I updated the title

@rileykarson
Copy link
Member

Do you mind isolating the change to a single commit as well? It probably won't matter w/ squash, but I've found branches with merges to be a little funky sometimes.

@ScottSuarez
Copy link
Contributor Author

sure @rileykarson

closing this in favor of #5584

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Cannot start a rolling update on an unhealthy Managed Instance Group
3 participants