Skip to content

Commit 26cf5b7

Browse files
committed
fix(google_gke): Add variable for GPU driver version
1 parent 85787df commit 26cf5b7

File tree

2 files changed

+10
-4
lines changed

2 files changed

+10
-4
lines changed

google_gke/cluster.tf

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -288,6 +288,10 @@ resource "google_container_node_pool" "pools" {
288288
content {
289289
type = local.node_pools_guest_accelerator[each.key].type
290290
count = local.node_pools_guest_accelerator[each.key].count
291+
292+
gpu_driver_installation_config {
293+
gpu_driver_version = local.node_pools_guest_accelerator[each.key].gpu_driver_version
294+
}
291295
}
292296
}
293297

google_gke/variables.tf

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -267,10 +267,12 @@ variable "node_pools_taints" {
267267

268268
variable "node_pools_guest_accelerator" {
269269
description = "Map containing node pools guest accelerator. Each node pool's name is the key. See locals.tf for defaults."
270-
type = map(map(string))
271-
default = {
272-
tf-default-node-pool = {}
273-
}
270+
type = map(object({
271+
type = string
272+
count = number
273+
gpu_driver_version = optional(string, "LATEST")
274+
}))
275+
default = {}
274276
}
275277

276278
variable "node_pools_spot_enabled" {

0 commit comments

Comments
 (0)