Parameterize GKE datapath provider (DEP-168)#255
Open
alex-hunt-materialize wants to merge 1 commit into
Open
Conversation
The gke module hardcoded ADVANCED_DATAPATH (Dataplane V2), but GKE cannot change the datapath provider on an existing cluster. Clusters built by the old terraform module use the legacy CNI, so adopting this module forced a full cluster rebuild. Default stays ADVANCED_DATAPATH; existing clusters can set LEGACY_DATAPATH or DATAPATH_PROVIDER_UNSPECIFIED to avoid replacement. Note the legacy CNI silently ignores NetworkPolicy resources. Refs DEP-168
Contributor
Author
|
@bosconi I don't know how to test this with an older cluster. I'm testing with creating a new one with the legacy datapath, but that doesn't truly test the upgrade path. Any chance you could give this a go pointing the context-graph's terraform module |
Member
|
Absolutely. I'll do that right now… |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The
gcp/modules/gkemodule hardcodeddatapath_provider = "ADVANCED_DATAPATH"(Dataplane V2 / eBPF CNI). GKE cannot change the datapath provider on an existing cluster, so clusters built with the legacy CNI (everything created by the old terraform module) could not adopt this module without a full cluster rebuild.datapath_providervariable togcp/modules/gke, defaulting toADVANCED_DATAPATH(no behavior change for current users). AcceptsADVANCED_DATAPATH,LEGACY_DATAPATH, andDATAPATH_PROVIDER_UNSPECIFIED.simpleandenterpriseGCP examples and pass it through to the gke module.NetworkPolicyresources, and that changing the value forces cluster replacement.Per discussion on the issue, this only parameterizes the CNI; network policy resources are still created by default (they are simply not enforced on the legacy datapath).
Refs DEP-168
Testing
Manually running the rust tests, once with the defaults and once with an overridden datapath_provider to use the legacy datapath.
🤖 Generated with Claude Code