This is derived from a GitHub issue for the IBM Cloud terraform provider. The request there is to make it possible to change the machine type of the worker nodes of a Kubernetes cluster.
It is not possible to change the machine type via terraform without destroying the Kubernetes cluster. A new API has to be added for this to be then exposed via terraform as far as I understood.
https://github.com/IBM-Cloud/terraform-provider-ibm/issues/527
| Idea priority | High |
By clicking the "Post Comment" or "Submit Idea" button, you are agreeing to the IBM Ideas Portal Terms of Use.
Do not place IBM confidential, company confidential, or personal information into any field.
The workaround is fine. At the time of this request, we did not work with worker pools. But in the meantime we do, so that works for us.
From Sai Vennam :
"As per the workaround defined by Chris, I wanted to add some details for Terraform. The IBM Cloud Terraform Provider implementation for IKS allows the user to define worker pools. This would allow you to change the worker type without destroying the cluster. User must define their own worker pools instead of simply setting the default worker-type for the default pool."
From Christopher Rosen:
"Yes we don't allow this in IKS or ROKS, you need to deploy a new pool and delete the default pool. Status changed to reflect this. "
Following up to see if you were able to test and resolve?
It depends on the process of switching worker pools. If I can just change the machine type in the resource definition and the terraform provider automatically creates the new worker pool and then deletes the old one, perfect. I did not test this yet.
The correct answer here is to create a new pool and delete the older pool, as the IKS team will not support changing the machine type in place. The flow to switch out worker pools is supported today. Does this satisfy the requirement?
reassigned to Sai Vennam
Ruben, thank you for the suggestion. The IKS team does feel this is within their scope. As indicated, we are working with you in the GH issue you opened toward a solution path.