Terragrunt generate block
Why
When creating repeatable DRY terraform, we will use a terragrunt generate
block
How
Terragrunt generate
block has several features:
- Overwrite
- Skip
How to use it
You will then need to create a file called terragrunt.hcl
in a new folder and paste in the below
Using the below structure, when we run terragrunt run-all init
it will create the file example.tf
in each directory
.
├── dev
│ └── terragrunt.hcl
├── prd
│ └── terragrunt.hcl
├── terragrunt.hcl
└── test
└── terragrunt.hcl
Want to make this site better? Open a PR or help fund hosting costs