
Learn to automate cloud infrastructure with Terraform in a hands-on course, installing and configuring Terraform, writing TF files, and deploying to AWS with providers, resources, variables, outputs, and modules.
Explore infrastructure as code with Terraform, using declarative .tf files and state management to create, update, and delete resources across AWS and other providers.
Install Terraform and the AWS CLI, configure credentials, and prepare your project folder across macOS and Linux, including aws configure and VSCode with a remote explorer for the virtual machine.
Explore your first Terraform script by configuring an AWS provider, deploying a simple S3 bucket, and using init, plan, apply, and destroy to manage live infrastructure.
Deploy an AWS EC2 instance using variables and outputs, configure the provider, reference AMI ID and instance type via variables, and expose the instance public IP via outputs.
Learn how Terraform state tracks resources, outputs, and code-to-infrastructure mappings, and compare local versus remote state with state locking to prevent conflicts.
Fetch the latest AWS AMI for Ubuntu using a Terraform data block to dynamically read the AMI id. Replace hard-coded AMI values with data sources to streamline EC2 provisioning.
Validate terraform syntax with terraform validate, format code with terraform fmt, then apply changes. See plans show in-place updates versus resource replacements like EC2 renaming or S3 bucket replacement.
Explore how Terraform's built-in functions enable dynamic, reusable configurations, using a random id suffix and lowercased S3 bucket names. See how the console tests functions and inspects resources.
Scale infrastructure with terraform using count and for_each to create multiple S3 buckets and EC2 instances, while using a locals map to assign names and types and output each IP.
Refactor a terraform ec2 config into a reusable module by creating a modules/ec2 folder, moving variables and outputs, and wiring the root module to pass instance map and ami id.
Explore public modules from the Terraform registry to provision an S3 bucket with versioning and access controls, and learn to initialize and apply with targeting to scope changes.
Recap infrastructure as code with Terraform, covering AWS resources like EC2 and S3, and the use of modules, variables, and state management.
Welcome to Hands-On Introduction to Infrastructure as Code with Terraform. I'm Lucas, a tech lead working in an international team, with a passion for helping beginners break into tech by learning modern tools through real, hands-on practice.
In this course, you’ll learn Terraform from scratch and build your confidence with Infrastructure as Code (IaC) — a key skill in DevOps, cloud engineering, and automation.
We’ll start with the basics: installing Terraform, setting up your AWS credentials, and understanding what Terraform actually does. Then, we’ll move on to real infrastructure: launching EC2 instances, creating S3 buckets, and organizing your code with variables, outputs, functions, and conditionals.
You’ll also learn how to:
Format and validate your code
Use count and for_each to scale resources
Understand and manage state
Write clean and reusable modules
Leverage powerful, community-built modules from the Terraform Registry
All lessons are short, focused, and based on real-world use cases. This course is perfect for beginners who want to get hands-on with cloud infrastructure and for developers who want to learn Terraform the right way.
No prior Terraform experience needed — just curiosity and basic AWS knowledge would be a plus.
Let’s demystify Terraform, step by step by learning today and let's take the first step toward becoming confident in Infrastructure as Code!