Terraform vs. CloudFormation: A Comprehensive Comparison for Migrating to AWS

DevSecOps | Automation | Provisioning | Amazon | Iac |

⚗ Kevin Summersill 🔋
5 min readFeb 3, 2023

--

Infrastructure as code (IAC) is an increasingly popular approach to managing and provisioning infrastructure, and two of the most commonly used tools in this area are Terraform and CloudFormation. Both tools allow you to automate the creation and management of cloud infrastructure, but they differ in their approach, capabilities, and target audience. In this article, we will compare Terraform and CloudFormation, and discuss which tool is better when migrating an on-prem environment to AWS.

Terraform and CloudFormation compared:

Terraform is an open-source IAC tool that supports a wide range of cloud providers, including AWS. It uses a declarative syntax, known as HashiCorp Configuration Language (HCL), to describe the desired state of resources. Terraform is highly extensible and can be used to manage a diverse set of infrastructure, from cloud to on-premises resources.

CloudFormation, on the other hand, is an AWS-specific tool that allows you to manage AWS resources through a JSON or YAML template. It’s tightly integrated with other AWS services, has good support for AWS resource types, and is well-suited for use within…

--

--

⚗ Kevin Summersill 🔋
⚗ Kevin Summersill 🔋

Written by ⚗ Kevin Summersill 🔋

Enterprise Solution Architect | Certified K8s Administrator/Developer ⚓ | SAFe SPC | Cert Terraform | AWS Solutions Architect | Dev*Ops/GitOps Engineer 🔥