Skip to content

Commit 33d106d

Browse files
authored
Merge pull request #1909 from hpe-dev-incubator/cms/blog/infrastructure-as-code-on-hpe-greenlake-using-terraform-–-part-2
Update Blog “infrastructure-as-code-on-hpe-greenlake-using-terraform-–-part-2”
2 parents 026d511 + 263084f commit 33d106d

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

content/blog/infrastructure-as-code-on-hpe-greenlake-using-terraform-–-part-2.md

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@ tags:
2121

2222
- - -
2323

24-
2524
The process of managing and provisioning computer data centers through machine-readable definition files, otherwise known as Infrastructure-as-Code (IaC), offers many significant benefits. It helps to increase operational agility, simplify management, reduce errors, and save cost. In this second post, I’ll explore how to extract more of the benefits of using IaC on HPE GreenLake through the use of Terraform.
2625

2726
## Let’s recap
@@ -38,7 +37,7 @@ terraform {
3837
      required_providers {
3938
         hpegl = {
4039
            source  = "hpe/hpegl"
41-
            version = "0.1.7"
40+
            version = "0.3.17"
4241
         }
4342
      }
4443
   }
@@ -257,7 +256,7 @@ Once your infrastructure is created, it will need to evolve over time in order t
257256

258257
### Use case 1: Stop this VM
259258

260-
To start, let’s keep things simple. You might want to just turn off the VMs that are part of an infrastructure when you don’t need them to save cost or limit your carbon impact on the planet. If you paid attention to the current configuration file, you’ll see that we inserted a power statement when originally creating the VM. While *poweron* is the only valid option when creating a new resource of type **hpegl\_vmaas\_instance**, other values are available for lifecycle management, such as *poweroff* and *suspend*.
259+
To start, let’s keep things simple. You might want to just turn off the VMs that are part of an infrastructure when you don’t need them to save cost or limit your carbon impact on the planet. If you paid attention to the current configuration file, you’ll see that we inserted a power statement when originally creating the VM. While *poweron* is the only valid option when creating a new resource of type **hpegl_vmaas_instance**, other values are available for lifecycle management, such as *poweroff* and *suspend*.
261260

262261
Locate the following section in your configuration file:
263262

@@ -356,7 +355,7 @@ Save the file, apply those changes, wait a little and check the details of the V
356355
## Debugging when things go wrong
357356

358357
In this post, I’ve showed you how to make sure the Terraform configuration file is valid before applying changes using the **terraform validate** command. To see more details during an apply command, you can also enable Terraform debug by simply setting up the TF_LOG environment variable. I suggest setting it up to DEBUG but other supported values are: TRACE, INFO, WARN and ERROR.
359-
358+
360359
```markdown
361360
export TF_LOG=DEBUG
362361
```
@@ -371,4 +370,4 @@ In [my first blog post](https://developer.hpe.com/blog/infrastructure-as-code-on
371370

372371
\-      [ Learn more about the HPE GreenLake Terraform provider](https://registry.terraform.io/providers/HPE/hpegl)
373372

374-
Don’t forget, you can always find other tutorials and articles on HPE GreenLake on the [HPE Developer blog](https://developer.hpe.com/blog).
373+
Don’t forget, you can always find other tutorials and articles on HPE GreenLake on the [HPE Developer blog](https://developer.hpe.com/blog).

0 commit comments

Comments
 (0)