Skip to content

Commit

Permalink
os_sku support added
Browse files Browse the repository at this point in the history
  • Loading branch information
Justin-DynamicD committed Sep 25, 2023
1 parent 1950af8 commit 72960c8
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 2 deletions.
2 changes: 2 additions & 0 deletions aks.tf
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ resource "azurerm_kubernetes_cluster" "main" {
only_critical_addons_enabled = local.node_default_pool.only_critical_addons_enabled
os_disk_size_gb = local.node_default_pool.os_disk_size_gb
os_disk_type = local.node_default_pool.os_disk_type
os_sku = local.node_default_pool.os_sku
tags = local.tags
vm_size = local.node_default_pool.vm_size
vnet_subnet_id = local.subnet_id
Expand Down Expand Up @@ -74,6 +75,7 @@ resource "azurerm_kubernetes_cluster_node_pool" "user" {
node_taints = local.node_user_pool_merged.node_taints
os_disk_size_gb = local.node_user_pool.os_disk_size_gb
os_disk_type = local.node_user_pool.os_disk_type
os_sku = local.node_user_pool.os_sku
os_type = local.node_user_pool.os_type
priority = local.node_user_pool.priority
eviction_policy = local.node_user_pool.priority == "Spot" ? local.node_user_pool.eviction_policy : null
Expand Down
2 changes: 1 addition & 1 deletion test/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ module "aks" {
node_user_pool = {
min_count = 1
node_count = 1
os_type = "Linux"
os_type = "Windows"
}
oms = {
enabled = true
Expand Down
4 changes: 3 additions & 1 deletion variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ variable "node_default_pool" {
only_critical_addons_enabled = optional(bool, true)
os_disk_size_gb = optional(number, 70)
os_disk_type = optional(string, "Ephemeral")
os_sku = optional(string, null)
vm_size = optional(string, "Standard_D2ds_v5")
})
description = "node default system pool for aks"
Expand All @@ -61,9 +62,10 @@ variable "node_user_pool" {
node_count = optional(number, 2)
node_labels = optional(map(any), {}) # needs defaults as we merge it later
node_taints = optional(list(string), []) # needs defaults as we concat it later
os_type = optional(string, "Linux")
os_disk_size_gb = optional(number, 120)
os_disk_type = optional(string, "Ephemeral")
os_sku = optional(string, null)
os_type = optional(string, "Linux")
priority = optional(string, "Regular")
spot_max_price = optional(number, -1)
vm_size = optional(string, "Standard_D4ds_v5")
Expand Down

0 comments on commit 72960c8

Please sign in to comment.