Skip to content

Commit

Permalink
add dataplane v2 support (#74)
Browse files Browse the repository at this point in the history
* add dataplane v2 support

* disable dataplane v2 by default
  • Loading branch information
pgvishnuram authored Aug 28, 2023
1 parent 125d212 commit 34484ca
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 3 deletions.
7 changes: 5 additions & 2 deletions terraform/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -143,10 +143,13 @@ resource "google_container_cluster" "primary" {
}
}
network_policy {
enabled = true
provider = "CALICO"
enabled = var.enable_dataplane_v2 ? false : true
provider = var.enable_dataplane_v2 ? "PROVIDER_UNSPECIFIED" : "CALICO"
}

# Setting dataplane v2 for GKE
datapath_provider = var.enable_dataplane_v2 ? "ADVANCED_DATAPATH" : "LEGACY_DATAPATH"

dynamic "resource_usage_export_config" {
for_each = var.enable_gke_metered_billing ? ["placeholder"] : []
content {
Expand Down
8 changes: 7 additions & 1 deletion terraform/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ variable "dns_managed_zone" {
}

variable "kube_version_gke" {
default = "1.24.12-gke.500"
default = "1.24.15-gke.1700"
description = "The kubernetes version to use in GKE"
}

Expand Down Expand Up @@ -581,3 +581,9 @@ variable "enable_istio" {
default = "false"
type = string
}


variable "enable_dataplane_v2" {
default = "false"
type = bool
}

0 comments on commit 34484ca

Please sign in to comment.