https://www.padok.fr/ https://www.padok.fr/en/blog https://www.padok.fr/en/blog/tag/technology https://www.padok.fr/en/blog/terraform-code-terragrunt This infrastructure is deployed in 3 distinct environments: A production environment: production

├── code/ │ └── contains the application code ├── terraform/ │ ├── dev/ │ │ ├── main.tf │ │ ├── providers.tf │ │ └── versions.tf │ ├── staging/ │ │ ├── main.tf │ │ ├── providers.tf │ │ └── versions.tf │ └── production/ │ ├── main.tf │ ├── providers.tf │ └── versions.tf └──...

This is where Terragrunt comes in handy, as it provides several functionalities to keep Terraform code DRY (Don’t Repeat Yourself).

That’s it for the theoretical part, let’s migrate the Terraform code for API A to Terragrunt.

Related Articles