What is AWS CloudFormation?
AWS CloudFormation is the Infrastructure as Code (IaC) service from AWS. With CloudFormation, you describe your entire cloud infrastructure in declarative templates (JSON or YAML) that serve as a single source of truth. CloudFormation handles orchestration, automatically determines the order of resource creation, and rolls back changes automatically on failures.
Key Features
- Declarative templates in JSON or YAML
- Automatic dependency resolution and rollback
- StackSets for multi-account and multi-region deployments
- Change Sets for preview before production deployments
- Drift Detection for configuration compliance
Common Use Cases
Automated Multi-Tier Applications: CloudFormation creates complete application stacks with VPC, subnets, security groups, load balancer, ECS cluster, and RDS. Development, staging, and production from one template.
Enterprise Governance with StackSets: Distribute security baselines, compliance configurations, and DevOps tooling automatically across hundreds of AWS accounts in your organization.
Serverless Applications with AWS SAM: SAM extends CloudFormation for serverless deployments and significantly simplifies Lambda, API Gateway, and DynamoDB configuration.
Benefits
- No cost for CloudFormation itself
- Complete versioning and audit trail via Git
- Automatic rollback prevents inconsistent states
- Native integration with all AWS services
Integration with innFactory
As an AWS Reseller, innFactory supports you with AWS CloudFormation: modular template architectures, migration to Infrastructure as Code, StackSets strategies for multi-account, and hybrid IaC with Terraform and CDK.
Typical Use Cases
Technical Specifications
Frequently Asked Questions
Is CloudFormation really free?
Yes. AWS charges no fees for CloudFormation itself. You only pay for the AWS resources that CloudFormation creates for you (e.g., EC2 instances, RDS databases).
How does CloudFormation differ from AWS CDK?
AWS CDK generates CloudFormation templates from TypeScript, Python, Java, or .NET code. CDK provides higher abstraction and reusability, while CloudFormation remains the deployment engine.
What happens when a stack update fails?
CloudFormation automatically rolls back to the last working state. All changes are reverted. You can also define rollback triggers based on CloudWatch alarms.
How many resources can a stack contain?
A stack can contain up to 500 resources. For larger infrastructures, use nested stacks or split the infrastructure into multiple independent stacks.
Can CloudFormation import existing resources?
Yes, with Resource Import you can bring manually created AWS resources into CloudFormation stacks without recreating them.