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

Add ability to choose between IP Aliases and Routes #6268

Closed

Comments

@danawillow
Copy link
Contributor

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 the 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 the issue is assigned to a user, that user is claiming responsibility for the issue. If the issue is assigned to "hashibot", a community member has claimed the issue already.

Description

(API-side changes in https://container.googleapis.com/$discovery/rest?version=v1beta1, not yet seeing on https://cloud.google.com/kubernetes-engine/docs/reference/rest/v1beta1/projects.locations.clusters)

In addition to useIpAliases, IPAllocationPolicy now supports useRoutes. We got rid of use_ip_aliases in 3.0.0 because it was the only possibility when a user specified an ip_allocation_policy block. Whoever implements this should think about the UX of the change and whether it makes sense to add the two booleans vs an enum, and whether these should be inside or outside the ip_allocation_policy block.

New or Affected Resource(s)

  • google_container_cluster

Potential Terraform Configuration

# Propose what you think the configuration to take advantage of this feature should look like.
# We may not use it verbatim, but it's helpful in understanding your intent.

References

@rileykarson
Copy link
Collaborator

fwiw, copy-paste of my thoughts from inside that bug:

I've been trying to think of ways to flip the default to VPC-native in Terraform for a little while, since newer GKE features tend to rely on it. I filed #5842 to capture my thoughts, but I think it'd be better to conform to the API's flip instead.

The API will return an ip_allocation_policy block on every response after this change, including one of use_ip_aliases or use_routes set to true, right? So if I send both set to false, one of them will come back true.

Right now, Terraform assumes that ip_allocation_policy being set means a cluster is VPC-native, and unset means it's routes-based. However, I see that allowRouteOverlap in beta can also apply to both types of clusters. It's probably most clear for our users if we transform the schema clientside a bit to collapse the pair of use_ booleans to an enum ("networking_mode" with "VPC NATIVE" and "ROUTES" as options, probably) at the top level, and to make allow_routes_overlap a top-level field as well.

@ghost
Copy link

ghost commented Jul 27, 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 👉 hashibot-feedback@hashicorp.com. Thanks!

@ghost ghost locked and limited conversation to collaborators Jul 27, 2020
@github-actions github-actions bot added service/container forward/review In review; remove label to forward labels Jan 14, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.