Getting Started with Terraform for Google Cloud

Beginner level

recommended experience

Live Instructor training

live Q&A with chat

Official Google Content

latest content from Google

Hands-on labs

Real world practical experience

Course overview

This course provides an introduction to using Terraform for Google Cloud. It enables learners to describe how Terraform can be used to implement infrastructure as a code and to apply some of its key features and functionalities to create and manage Google Cloud infrastructure. Learners will get hands-on practice building Google Cloud resources using Terraform.

In this course you will

  • Define the business need for infrastructure as code and the benefits of using it in your environment.

  • Explain the features and functionalities of Terraform.

  • Use Terraform resources, variables, and output values to create Google Cloud infrastructure resources.

  • Use Terraform modules to build reusable configurations.

  • Explain Terraform state and its importance.

Course topics

Module 01: Introduction to Terraform for Google Cloud

Topics

๐Ÿ”ธWhat is infrastructure as code (IaC)?

๐Ÿ”ธProblems IaC can solve

๐Ÿ”ธBenefits of IaC

๐Ÿ”ธProvisioning versus configuration

๐Ÿ”ธImperative versus declarative approach

๐Ÿ”ธTerraform overview

๐Ÿ”ธTerraform features

๐Ÿ”ธIaC configuration workflow

๐Ÿ”ธTerraform use cases

๐Ÿ”ธHow to use Terraform

๐Ÿ”ธRunning Terraform in production

๐Ÿ”ธInstalling Terraform

๐Ÿ”ธAuthentication for Google Cloud

Objectives

๐Ÿ”ธDefine infrastructure as code.

๐Ÿ”ธExplain the features and benefits of using Terraform.

๐Ÿ”ธExplain the use case of Terraform for Google Cloud.

๐Ÿ”ธDescribe how to use Terraform for Google Cloud.

Activities

๐Ÿ”ธ1 quiz

Module 02: Terms and concepts

Topics

๐Ÿ”ธThe Author phase

๐Ÿ”ธTerraform Directory structure

๐Ÿ”ธIntroduction to HCL syntax

๐Ÿ”ธResources

๐Ÿ”ธVariables

๐Ÿ”ธState

๐Ÿ”ธModules

๐Ÿ”ธTerraform commands

๐Ÿ”ธterraform init

๐Ÿ”ธterraform plan

๐Ÿ”ธterraform apply

๐Ÿ”ธterraform fmt

๐Ÿ”ธterraform destroy

๐Ÿ”ธTerraform Validator tool

๐Ÿ”ธWhy use the Terraform Validator tool

๐Ÿ”ธValidation workflow

๐Ÿ”ธTerraform Validator use cases

Objectivies

๐Ÿ”ธUpon completion of this module, the student will be able to:

๐Ÿ”ธExplain the Terraform workflow.

๐Ÿ”ธCreate basic configuration files within Terraform.

๐Ÿ”ธExplain the purpose of a few Terraform commands.

๐Ÿ”ธDescribe the Terraform Validator tool.

๐Ÿ”ธCreate, update, and destroy Google Cloud resources using Terraform.

Activities

๐Ÿ”ธ1 lab

๐Ÿ”ธ1 quiz

Module 03: Writing Infrastructure Code for Google Cloud

Topics

๐Ÿ”ธIntroduction to Resources

๐Ÿ”ธResources overview

๐Ÿ”ธSyntax

๐Ÿ”ธExample

๐Ÿ”ธRefer a resource attribute

๐Ÿ”ธConsiderations to define a resource block

๐Ÿ”ธMeta-arguments for resources

๐Ÿ”ธResource dependencies

๐Ÿ”ธImplicit dependency

๐Ÿ”ธExplicit dependency

๐Ÿ”ธIntroduction to Variables

๐Ÿ”ธOverview

๐Ÿ”ธSyntax to declare a variable

๐Ÿ”ธSyntax to reference and assign a value to a variable

๐Ÿ”ธVariables best practices

๐Ÿ”ธIntroduction to output values

๐Ÿ”ธOutput values overview

๐Ÿ”ธBest practices

๐Ÿ”ธTerraform Registry and CFT

๐Ÿ”ธIntroduction to Terraform Registry

๐Ÿ”ธIntroduction to CFT

Objectives

๐Ÿ”ธUpon completion of this module, the student will be able to:

๐Ÿ”ธDeclare the resources within Terraform.

๐Ÿ”ธExplain implicit and explicit resource dependencies.

๐Ÿ”ธUse variables and output values within the root configuration.

๐Ÿ”ธExplain Terraform Registry and Cloud Foundation Toolkit.

Activities

๐Ÿ”ธ1 lab

๐Ÿ”ธ1 quiz

Module 04: Organizing and Reusing Configuration with Terraform Modules

Topics

๐Ÿ”ธIntroduction to modules:

๐Ÿ”ธWhy are modules needed

๐Ÿ”ธWhat is a module?

๐Ÿ”ธExample

๐Ÿ”ธReusing configurations by using modules

๐Ÿ”ธModule sources

๐Ÿ”ธCalling a module into the source configuration

๐Ÿ”ธUsing variables to parameterize your configuration

๐Ÿ”ธPass resource attributes using output variables

๐Ÿ”ธModule use cases, benefits, and best practices

Objectives

๐Ÿ”ธUpon completion of this module, the student will be able to:

๐Ÿ”ธDefine Terraform modules.

๐Ÿ”ธUse modules to reuse configurations.

๐Ÿ”ธUse modules from the public registry.

๐Ÿ”ธUse input variables to parameterize configurations.

๐Ÿ”ธUse output values to access resource attributes outside the module.

Activities

๐Ÿ”ธ1 lab

๐Ÿ”ธ1 quiz

Module 05: Introduction to Terraform State

Topics

๐Ÿ”ธIntroduction to Terraform state

๐Ÿ”ธHow information is stored in a Terraform state file

๐Ÿ”ธWays to save a state file

๐Ÿ”ธStoring a state file in a Cloud Storage bucket

๐Ÿ”ธIssues when storing the Terraform state locally

๐Ÿ”ธBenefits of storing a state file in a Cloud Storage bucket

๐Ÿ”ธProcess of storing a Terraform state file remotely in a Cloud Storage bucket

๐Ÿ”ธTerraform state best practices

Objectives

๐Ÿ”ธUpon completion of this module, the student will be able to:

๐Ÿ”ธDefine Terraform state.

๐Ÿ”ธList the benefits of storing the state file remotely.

๐Ÿ”ธExplain how to store the Terraform state in a Cloud Storage bucket.

๐Ÿ”ธExplain Terraform state best practices.

Activities

๐Ÿ”ธ1 lab

๐Ÿ”ธ1 quiz

Class dates

Getting Started with Terraform for Google Cloud - schedule

Have Questions?

Send us a quick message and we'll be happy to answer any questions you have.

ยฉ Copyright 2025. Axalon. All rights reserved.