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

Upgrade_settings block for google_container_node_pool does not appear to be implemented. #5310

Closed
pbrumblay opened this issue Jan 3, 2020 · 4 comments
Assignees
Labels

Comments

@pbrumblay
Copy link

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • Please do not leave "+1" or "me too" comments, they generate extra noise for issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment
  • If an issue is assigned to the "modular-magician" user, it is either in the process of being autogenerated, or is planned to be autogenerated soon. If an issue is assigned to a user, that user is claiming responsibility for the issue. If an issue is assigned to "hashibot", a community member has claimed the issue already.

Terraform Version

Terraform v0.12.18

  • provider.google v3.3.0

Affected Resource(s)

  • google_v3.3.0

Terraform Configuration Files

resource "google_container_node_pool" "primary_pool" {
  name       = "primary"
  location   = var.cluster_region
  cluster    = google_container_cluster.gke_cluster.name
  autoscaling {
    min_node_count = var.min_nodes_per_zone
    max_node_count = var.max_nodes_per_zone
  }
  initial_node_count = var.min_nodes_per_zone
  management {
    auto_repair = true
    auto_upgrade = false
  }
  project = var.cluster_project_id

  node_config {
    machine_type = var.node_machine_type
    service_account = var.node_service_account
  }

  version = "1.13.11-gke.14"

  upgrade_settings {
    max_surge = 2
    max_unavailable = 0
  }
}

Debug Output

https://gist.github.com/pbrumblay/1b49d686f3382c0486d29ad7e3f0c10f

Panic Output

N/A

Expected Behavior

Terraform plan should have processed the upgrade_settings block properly.

Actual Behavior

The provider errored out indicating it did not expect the upgrade_settings block.

Error: Unsupported block type

  on ../../modules/gke/main.tf line 75, in resource "google_container_node_pool" "primary_pool":
  75:   upgrade_settings {

Blocks of type "upgrade_settings" are not expected here.

Steps to Reproduce

  1. Configure a google_container_cluster resource.
  2. Configure a google_container_node_pool as above.
  3. terraform plan

References

This PR updates documentation but does not appear to include the implementation for the upgrade_settings block: #4926

I would have expected that PR to, at a minimum, also include modifications to this file: https://github.com/terraform-providers/terraform-provider-google/blob/master/google/resource_container_node_pool.go. It feels like an incomplete merge. That said this is just a guess -- I'm not an expert on this codebase by any means.

@ghost ghost added the bug label Jan 3, 2020
@edwardmedia edwardmedia self-assigned this Jan 3, 2020
@edwardmedia
Copy link
Contributor

@pbrumblay the feature is in beta. You may want to check out https://github.com/terraform-providers/terraform-provider-google-beta/blob/master/google-beta/resource_container_node_pool.go. I am closing this issue. You may reopen this if you have more questions about it. Thanks

@pbrumblay
Copy link
Author

Ok @edwardmedia . I'll omit this from my implementation and watch to see when the provider implements this properly.

@pbrumblay
Copy link
Author

Hmm... I wasn't aware that the google provider was split into "google" and "google-beta". I don't know if this is new for 0.12 or if I've just never used a beta feature before. I'll have to consider switching to google-beta. https://www.terraform.io/docs/providers/google/guides/provider_reference.html

@ghost
Copy link

ghost commented Feb 3, 2020

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. If you feel I made an error 🤖 🙉 , please reach out to my human friends 👉 [email protected]. Thanks!

@ghost ghost locked and limited conversation to collaborators Feb 3, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants