Skip to content

Commit af802ae

Browse files
zioprotolonegunmanb
authored andcommitted
explain in Readme why can't upgrade var.kubernetes_version and var.orchestrator_version at the same time
1 parent 55fd2ce commit af802ae

File tree

1 file changed

+39
-0
lines changed

1 file changed

+39
-0
lines changed

examples/multiple_node_pools/README.md

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,3 +72,42 @@ kubectl get nodes # check nodes version
7272

7373
In the `az aks list` output you will have `KubernetesVersion` and `CurrentKubernetesVersion` both at 1.27.7
7474
The control plane version will be 1.27.7 and the nodes will be 1.27.7.
75+
76+
## Note on Issue #465
77+
78+
The current implementation does not allow to upgrade `var.kubernetes_version` and `var.orchestrator_version` at the same time.
79+
80+
We can test at this point a simultaneous upgrade to 1.28.3:
81+
82+
```
83+
terraform apply -var="kubernetes_version=1.28.3" -var="orchestrator_version=1.28.3"
84+
```
85+
This will generate a plan where the azure_kubernetes_cluster resource is updated in place and the system node pool is updated.
86+
87+
```
88+
# module.aks.azurerm_kubernetes_cluster.main will be updated in-place
89+
~ resource "azurerm_kubernetes_cluster" "main" {
90+
id = "/subscriptions/<redacted>/resourceGroups/4c273d71bc7898d6-rg/providers/Microsoft.ContainerService/managedClusters/prefix-4c273d71bc7898d6-aks"
91+
name = "prefix-4c273d71bc7898d6-aks"
92+
tags = {}
93+
# (29 unchanged attributes hidden)
94+
95+
~ default_node_pool {
96+
name = "nodepool"
97+
~ orchestrator_version = "1.27.7" -> "1.28.3"
98+
tags = {}
99+
# (22 unchanged attributes hidden)
100+
}
101+
102+
# (4 unchanged blocks hidden)
103+
}
104+
```
105+
106+
that will fail with the following error:
107+
108+
```
109+
│ Error: updating Default Node Pool Agent Pool (Subscription: "<redacted>"
110+
│ Resource Group Name: "4c273d71bc7898d6-rg"
111+
│ Managed Cluster Name: "prefix-4c273d71bc7898d6-aks"
112+
│ Agent Pool Name: "nodepool") performing CreateOrUpdate: agentpools.AgentPoolsClient#CreateOrUpdate: Failure sending request: StatusCode=0 -- Original Error: Code="NodePoolMcVersionIncompatible" Message="Node pool version 1.28.3 and control plane version 1.27.7 are incompatible. Minor version of node pool version 28 is bigger than control plane version 27. For more information, please check https://aka.ms/aks/UpgradeVersionRules"
113+
```

0 commit comments

Comments
 (0)