
Discover how Terraform, an open-source infrastructure as code tool from HashiCorp, lets you script and manage cross-cloud infrastructure with the declarative language HCL, including AWS resources like S3.
Discover what infrastructure as code is and why it matters for tracking who created resources and why, then learn how Terraform enables version control, cross-cloud infrastructure from development to production.
Install Terraform, set up an AWS account, and configure credentials on your local system with a code editor of your choice across macOS, Windows, or Linux.
Download the Terraform binary for your OS from the official site, extract it (it's not an installer), and update your path. Restart the shell and run terraform to verify.
Download and install the aws cli, create an iam user, generate access keys, configure a named profile, and test by listing your iam users.
Master the basics of Terraform by creating your first Terraform file, understanding the state file, and configuring credentials, input variables, and outputs.
Create a hello world terraform file and initialize with terraform init to set up aws provider and dependencies; then plan, apply, and destroy as needed.
Learn to configure the AWS provider in Terraform, supply credentials via access key/secret key or a profile, and run init and plan.
Master Terraform variables, including strings, maps, lists, and booleans, learn how to declare, consume, and output them, including multiline strings and practical examples in AWS infrastructure.
Learn to define input variables and outputs in Terraform to pass dynamic values, view results, and handle sensitive data in outputs.
This section introduces AWS Terraform components, including S3 bucket creation and uploads, EC2 instances, application load balancers and target groups, CloudWatch and SNS topics, and variable usage with destroy workflows.
Create an S3 bucket with Terraform, upload a test file, and manage resources through plan, apply, and destroy, including ACL, tags, and e-tags.
Launch an ec2 instance using terraform, creating a key pair and security group within the default vpc. Understand variables, ami selection, and plan/apply workflow.
Recaps creating basic AWS resources with Terraform: S3 bucket with file upload, an EC2 instance, and security groups, using variables and docs, and previews modules for enterprise setups.
Learn why Terraform modules enable separation of concerns, reusable components, and easier maintenance for infrastructure by reducing duplicate code and centralizing changes for load balancer configuration via input variables.
learn to create your first Terraform module, organize a module folder, import it into main.tf, and run init, plan, and apply to provision a security group and an EC2 instance.
Learn to refactor a terraform project by splitting the security group into its own module, exporting its id, and passing that output as an input to the EC2 instance module.
Reuse a Terraform module to create multiple instances with different inputs from the same model. Learn about modules, state files, and the init, plan, and apply workflow.
Address the multiple environments problem by using terraform workspaces to apply the same terraform file across development, staging, and production with environment-specific inputs.
Learn to create and switch Terraform workspaces (staging and production) to deploy the same scripts with environment-specific resource names and per-workspace state.
Define environment specific local variables with a lookup function in Terraform to resolve per-environment IDs across staging, default, and production workspaces.
Learn to create and share environment-specific variables across Terraform modules using a shared variables module, import it across models, and apply environment suffixes with workspace mapping.
Recap the key Terraform concepts: modules, inputs, exports, and dependencies. Explore workspaces, environment-specific local variables, and shared variables to support production-level infrastructure and a two-tiered architecture.
Master Terraform for AWS by building a production‑grade infrastructure with an application load balancer, security groups, launch config, and autoscaling across staging and production.
Set up a Terraform for AWS project with shared and network modules, create security groups for staging, and configure a VPC and subnets, provider, and staging workspace.
Master the setup of an AWS application load balancer with a target group and listener using Terraform modules, wiring public and private security groups across two subnets in different zones.
Configure a launch configuration for the auto scaling group, specifying ami id, instance type, key name, security groups, and user data for the staging environment using terraform.
Configure an AWS auto scaling group with Terraform using a launch configuration, a target group, and a load balancer, with health checks and staging and production environments.
Switch to a production workspace and run Terraform init, plan, and apply to replicate staging resources in production. Verify security groups, load balancer, target groups, and health checks.
Why this course ?
In current Cloud Industry, Terraform is considered as one of the leaders for Infrastructure as a code platform. With its flexibility and compatibility with many different cloud providers like (AWS, Azure, GoogleCloud, Digital Ocean and many others), Terraform makes it Very easy to manage the workloads that are provisioned in different cloud providers at one place.
Having the skills to write and maintain the infrastructure using Terraform gives an edge to a cloud practitioner's profile.
In this course I have covered a lot of ground on Terraform which will help all levels of students (Beginner to pro) to get a good understanding and practical implementation.
This course is structured in an Hands On way and students who practice along with the lessons will get the most out of it.
Course Structure
Introduction Section:
What is Terraform ?
What & Why Infrastructure as a code ?
Course Requirements
Installing Terraform
Setup AWS CLI
Terraform Basics:
First Terraform File
What is state file and its importance
Different ways to give access to tf
Terraform Variables and its uses
Terraform input variables
Terraform output variables
Basic AWS Components:
Introduction
Create S3 bucket and upload files
Launch new EC2 instance
Next steps
Advanced Terraform Concepts:
Terraform Modules & Why we need them ?
First Terraform Module
Providing Inputs to the Module
Module Reuse with different Inputs
Multiple Environments Problem
Terraform Workspaces
Environment Specific Local Variables
Shared Vars for different Environments
Conclusion
AWS Project:
Project Introduction
Project Setup & Security Groups
Setup ALB and Target Groups
Setup Launch Configurations
Setup Autoscaling & Launching EC2 instances
Provision Multiple Environments(staging/production)