Skip to content

Commit

Permalink
add nodepool support for max_pods_per_node
Browse files Browse the repository at this point in the history
  • Loading branch information
robo-cap committed Mar 11, 2024
1 parent 5ac3a65 commit 3131832
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions modules/workers/locals.tf
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ locals {
image_id = var.image_id
image_type = var.image_type
kubernetes_version = var.kubernetes_version
max_pods_per_node = min(max(var.max_pods_per_node, 1), 110)
memory = local.memory
mode = var.worker_pool_mode
node_cycling_enabled = false
Expand Down
2 changes: 1 addition & 1 deletion modules/workers/nodepools.tf
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ resource "oci_containerengine_node_pool" "workers" {
for_each = var.cni_type == "npn" ? [1] : []
content { # VCN-Native requires max pods/node, nsg ids, subnet ids
cni_type = "OCI_VCN_IP_NATIVE"
max_pods_per_node = min(max(var.max_pods_per_node, 1), 110)
max_pods_per_node = each.value.max_pods_per_node
pod_nsg_ids = compact(tolist(each.value.pod_nsg_ids))
pod_subnet_ids = compact(tolist([each.value.pod_subnet_id]))
}
Expand Down

0 comments on commit 3131832

Please sign in to comment.