terragrunt
terragrunt copied to clipboard
Add information about Terraform provider plugin caching
Background
On every Terragrunt plan/apply, it will download the provider plugins over and over again (not sure if this is a bug in itself), consuming several hundred megabytes on every Terragrunt run, but after enabling the plugin_cache_dir it stops doing so.
Suggested solution
In the caching section of the website I think there should be a page where people are reminded to configure Terraform's provider plugin caching. Specifically to create a plugin_cache_dir and add it to ~/.terraformrc as it's very useful when working with multiple Terragrunt folders that depend on each other and have some shared dependencies like the AWS provider plugin.
I've been using this feature for several months now, and I can confirm that it has several advantages.
Above all, it improves execution speed for massive actions, such as plan/apply on several modules!
I proposed a PR to add a section in the documentation ;)
Unfortunately, this will not work properly with run-all commands, Why Terraform’s built-in provider caching doesn’t work.
Seems Terragrunt has implemented its own provider caching! 🎉 #3001 I'm gonna try it out.
It also means this issue is a duplicate of #2920.
Yes indeed. Please try out Terragrunt's new provider caching feature: https://terragrunt.gruntwork.io/docs/features/provider-cache/.
There is more work to do, but that's captured in https://github.com/gruntwork-io/terragrunt/issues/2920, so closing in favor of that issue.