CloudFormation
March 28, 2025
-
Cloud Formation is a declarative way of outlining yours AWS infrastructure, for any resources ( most of them are supported)
-
For example, within a CloudFormation template, you say:
- I want a security group
- I want two EC2 instances using this security group
- I want an S3 bucket
- I want a load balancer (ELB) in front of these machines
-
Then CloudFormation creates those for you, int he right order, with the exact configuration that you specify
Benefits of AWS CloudFormation
- Each resources within the stack is tagged with an identifier so you can easily see how much a stack cost you
- You can estimate the costs of your resources using the Cloud Formation template
- Savings strategy: In Dev, you could automation deletion of templates at 5 PM and recreated at 8 AM, safely
- Productivity
- Ability to destroy and re-create an infrastructure on the cloud on the fly
- Automated generation of Diagram for you templates!
- Declarative programming (no need to figure out ordering and orchestration)
- Don't re-invent the wheel
- Leverage existing templates on the web!
- Leverage the documentation
- Supports (almost) all AWS resources:
- Everything we'll see in this course is supported
- You can use "custom resources" for resources that are not supported