Terraform — 5 Ways To Create Infrastructure in Multiple Environments
Exploring Different ways of creating infrastructure in different environments with Terraform
Terraform is an open-source infrastructure as a code software tool that provides a consistent CLI workflow to manage hundreds of cloud services. Terraform codifies cloud APIs into declarative configuration files.
Most of the time we deploy the infrastructure in multiple environments. We need these environments for the development, stage, testing, and production. It’s very important to write a maintainable and scalable Terraform configuration that should allow us to provision infrastructure on these different environments.
In this post, we will see the different ways of provisioning infrastructure in multiple environments. Each of them has pros and cons.
- Introduction
- Prerequisite
- Using Folders — Method 1
- Using Folders — Method 2
- Workspaces
- Modules
- Terragrunt
- Summary
- Conclusion