Skip to content

Commit 34d397d

Browse files
Adam SmithAdam Smith
authored andcommitted
fix: prevent (failing) recreation of nodepools on rerun
1 parent 8249d10 commit 34d397d

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

gke.tf

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,18 @@ resource "google_container_node_pool" "nodes" {
103103

104104
#trivy:ignore:AVD-GCP-0048
105105
node_config {
106-
machine_type = var.gke_nodes_machine_type
106+
machine_type = var.gke_nodes_machine_type
107+
108+
resource_labels = {
109+
"goog-gke-node-pool-provisioning-model" = "on-demand"
110+
}
111+
112+
kubelet_config {
113+
cpu_cfs_quota = false
114+
pod_pids_limit = 0
115+
cpu_manager_policy = ""
116+
}
117+
107118
metadata = { disable-legacy-endpoints = true }
108119
oauth_scopes = ["https://www.googleapis.com/auth/cloud-platform"]
109120
service_account = google_service_account.gke_service_account.email

0 commit comments

Comments
 (0)