0
0
Terraformcloud~30 mins

Terraform Cloud overview - Mini Project: Build & Apply

Choose your learning style9 modes available
Terraform Cloud overview
📖 Scenario: You are working as a cloud engineer for a small company. Your team wants to start using Terraform Cloud to manage infrastructure safely and collaboratively.Terraform Cloud helps teams store infrastructure code, run Terraform plans and applies remotely, and keep track of changes.
🎯 Goal: Build a simple Terraform Cloud workspace configuration that connects to a version control repository and sets up a basic infrastructure plan.
📋 What You'll Learn
Create a Terraform Cloud organization variable
Configure a Terraform Cloud workspace with a VCS repository
Set the Terraform Cloud workspace to use the correct Terraform version
Add a basic Terraform configuration file to define infrastructure
💡 Why This Matters
🌍 Real World
Terraform Cloud is used by teams to collaborate on infrastructure as code, manage state remotely, and automate infrastructure deployments safely.
💼 Career
Understanding Terraform Cloud workspace configuration is essential for cloud engineers and DevOps professionals managing infrastructure with Terraform in a team environment.
Progress0 / 4 steps
1
Create Terraform Cloud organization variable
Create a variable called terraform_cloud_organization and set it to the string "my-org" which represents your Terraform Cloud organization name.
Terraform
Need a hint?

Use the syntax variable_name = "value" to create a string variable.

2
Configure Terraform Cloud workspace with VCS repository
Create a Terraform resource block terraform_cloud_workspace named example that sets name to "example-workspace", organization to the variable terraform_cloud_organization, and configures vcs_repo with identifier set to "my-org/my-repo" and branch set to "main".
Terraform
Need a hint?

Use a resource block with nested vcs_repo block to configure the workspace.

3
Set Terraform version for the workspace
Inside the terraform_cloud_workspace resource named example, add the attribute terraform_version and set it to "1.5.0" to specify the Terraform version used in this workspace.
Terraform
Need a hint?

Add the terraform_version attribute inside the workspace resource block.

4
Add basic Terraform configuration file
Create a Terraform configuration file named main.tf that defines a resource aws_s3_bucket named example_bucket with bucket set to "my-example-bucket-12345" and acl set to "private".
Terraform
Need a hint?

Use a resource block with the AWS S3 bucket resource type and set the required attributes.