CLOUD LABS
Provisioning Infrastructure as Code—From Zero to Hero
In this Cloud Lab, you’ll use IAC with AWS SAM, CloudFormation, and Terraform to create an app that interacts with AWS services.
beginner
Certificate of Completion
Learning Objectives
Infrastructure as Code (IaC) gives developers the power to build and deploy services using code, so they don’t have to do much manual work. To make this method work even better, developers break down big, complex architectures into smaller, more manageable pieces. They then write code to create these parts and ensure they connect smoothly with other services.
In this Cloud Lab, you’ll explore the power of Infrastructure as Code (IaC) with AWS CloudFormation, AWS SAM, and Terraform. You will construct a comprehensive infrastructure on the AWS Cloud that includes AWS DynamoDB, Lambda function, and an API Gateway. With these cloud technologies, you will use a ToDo-list React application that interacts with your IaC-deployed infrastructure.
By the end of this Cloud Lab, you’ll be able to use Infrastructure as Code and develop an understanding of its principles and practical application of AWS CloudFormation, AWS SAM, and Terraform in constructing and managing cloud-based architectures.
The following is the high-level architecture diagram of the infrastructure you’ll create in this Cloud Lab:
What is Infrastructure as Code (IaC)?
Infrastructure as Code (IaC) is the practice of defining and managing infrastructure through code, rather than manual configuration. Rather than clicking through a console, you describe the desired infrastructure state in files that can be versioned, reviewed, tested, and applied consistently.
IaC is useful because it turns infrastructure into a repeatable process:
The same environment can be recreated in minutes.
Changes are tracked and auditable.
Teams can collaborate using pull requests and code review.
Rollbacks become easier because history is preserved.
Why IaC is a “from zero to hero” skill
Cloud platforms are flexible, but that flexibility creates risk. Without automation, environments drift, setups become inconsistent across teams, and small changes can cause unexpected outages.
IaC gives you control and predictability. It’s one of the fastest ways to level up from “I can deploy something” to “I can operate infrastructure responsibly.”
The core IaC workflow
Regardless of the tool, most IaC workflows share the same loop:
Define: Write declarations for networks, compute, storage, security policies, and other resources.
Plan: Preview what will change before anything happens. This step reduces accidental deletions and surprises.
Apply: Implement changes and synchronize the real environment with the declared configuration.
Manage drift: Detect when infrastructure changes outside your IaC process and decide how to reconcile them.
Promote across environments: Use the same code patterns to create dev, staging, and production environments with controlled differences.
What to get right early when learning IaC
A few early habits make IaC far easier to scale:
State management: Understand how your tool tracks real resources.
Modularity: Reuse common infrastructure patterns through modules/stacks.
Separation of concerns: Keep foundational infrastructure separate from app-level resources when possible.
Secrets and credentials: Avoid hardcoding; use managed secret systems and least privilege.
Review and automation: Treat infra changes like code changes, PRs, reviews, and automated checks.
When IaC pays off the most
IaC is especially valuable when you:
Need consistent environments for multiple teams.
Want reliable disaster recovery and reproducibility.
Manage compliance and audit requirements.
Run multiple deployments per day through CI/CD.
Operate at scale where manual changes are risky.
The more production your infrastructure becomes, the less optional IaC becomes.
Relevant Courses
Use the following content to review prerequisites or explore specific concepts in detail.
Felipe Matheus
Software Engineer
Adina Ong
Senior Engineering Manager
Clifford Fajardo
Senior Software Engineer
Thomas Chang
Software Engineer
Copyright ©2026 Educative, Inc. All rights reserved.