Skip to content

Commit 6918fc1

Browse files
committed
Update Blog “scale-kubernetes-clusters-using-hpe-greenlake-terraform-provider”
1 parent 04f6c8f commit 6918fc1

File tree

4 files changed

+16
-10
lines changed

4 files changed

+16
-10
lines changed

content/blog/scale-kubernetes-clusters-using-hpe-greenlake-terraform-provider.md

Lines changed: 16 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
---
2-
title: Update Kubernetes Clusters using HPE GreenLake Terraform Provider
3-
date: 2023-05-11T15:47:11.101Z
2+
title: Upgrade Kubernetes Clusters using HPE GreenLake Terraform Provider
3+
date: 2023-05-12T03:06:12.264Z
44
author: Tanushi Agarwal
5-
authorimage: /img/Avatar1.svg
5+
authorimage: /img/photoforblog.jpg
66
disable: false
77
---
88
IaC or Infrastructure as code is an practice of automating the process of managing and provisioning infrastructure through code instead of manual processes. It gives organizations tools to create, manage, and destroy compute resources by statically defining and declaring these resources in codeblocks. It helps to increase operational agility, simplify management, reduce errors, and save cost.
@@ -70,9 +70,11 @@ resource hpegl_caas_cluster test {
7070

7171
For Kubernetes version upgrade, we need to specify the new version of kubernetes that is available for upgrade in the resources block.
7272

73-
1. kubernetes_version: *Use the Kubernetes version that pops up on the cluster details page in the UI*
73+
1. **kubernetes_version**: *Use the Kubernetes version that pops up on the cluster details page in the UI.*
74+
75+
![](/img/blog1.jpg)
76+
7477

75-
![UI shows new versions that are available](/img/blog1.jpg)
7678

7779
Below is the reference Terraform configuration for updating the cluster's kubernetes version.
7880

@@ -203,18 +205,22 @@ Apply complete! Resources: 0 added, 1 changed, 0 destroyed.
203205
For OS version upgrade, we need to specify the new version of OS Image that is available for upgrade & the name of the OS Image in the worker node block.
204206

205207

206-
**Note**: The OS version is specific to a worker node pool. All the nodes in the worker node pool will be updated to the same OS version. However, we can have different node pool supporting different OS versions.
208+
**Note**: The OS version is specific to a worker node pool. All the nodes in the worker node pool will be updated to the same OS version. However, we can have different node pools supporting different OS versions.
207209

208210
The worker node block consist of following fields -
209211

210212
1. **name**: *The name of the worker nodepool. If you wish to update default or existing worker node pool, enter the name of that node pool or you can create a new node pool by specifying a new name.*
211213
2. **machine_blueprint_id**: *Fill in the ID for the machine blueprint that is already present in HPE GreenLake Central for your tenant. Use the machine blueprint data source to retrieve the machine blueprint ID.*
212214
3. **count**: *Add the number of nodes to be present as part of this node pool. We can scale up & down by updating the count value here.*
213-
4. **os_image**: *The name of the OS image. Use the machine blueprint data source to retrieve the name of OS image*
214-
5. **os_version**: *The version to be upgraded to. We can get this version in the UI. Whenever there is a new version present, UI will pop up a banner mentioning the new version.*
215+
4. **os_image**: *The name of the OS image. Use the machine blueprint data source to retrieve the name of OS image.*
216+
5. **os_version**: *The version to be upgraded to. We can get this version in the UI. Whenever there is a new version available, UI will pop up a banner mentioning the new version.*
215217

216218
We can find the new version by clicking on the **Actions->Update OS** button on the right side of cluster's details page.
217219

220+
![](/img/blog2.jpg)
221+
222+
![](/img/blog4.jpg)
223+
218224
Below is the reference Terraform configuration for updating the worker nodepool's OS version.
219225

220226
```hcl
@@ -269,7 +275,7 @@ worker_nodes {
269275

270276
# Ready to Terraform plan
271277

272-
Terraform plan is a dry run that lets you preview the changes that Terraform plans to make to your infrastructure based on the data you provide in your Terraform file. To see this, run **terraform plan**
278+
Again, to preview the changes, do a dry run by running **terraform plan**
273279

274280
```shellsession
275281
$ terraform plan
@@ -305,7 +311,7 @@ Note: You didn't use the -out option to save this plan, so Terraform can't guara
305311

306312
# Ready to Terraform apply
307313

308-
Terraform apply executes the actions proposed in the Terraform plan and updates the resources. Run the command **terraform apply** and type **yes** when asked to **Enter a value**.
314+
Run the command **terraform apply** and type **yes** when asked to **Enter a value**.
309315

310316
```shellsession
311317
$ terraform apply

static/img/blog3.jpg

22.1 KB
Loading

static/img/blog4.jpg

22.2 KB
Loading

static/img/photoforblog.jpg

2 MB
Loading

0 commit comments

Comments
 (0)