Search code examples
terragrunt

Auto approve apply external dependency for all Terragrunt modules


When I run terragrunt run-all plan I get prompted to approve an external dependency for each module I have.

How can I auto approve it for all modules?

Module:          /Users/mugen/tf/environments/dev/module1
External dependency:     /Users/mugen/tf/environments/global/iam
Should Terragrunt apply the external dependency? (y/n) y
...
Module:          /Users/mugen/tf/environments/dev/modulen
External dependency:     /Users/mugen/tf/environments/global/iam
Should Terragrunt apply the external dependency? (y/n) y

Solution

  • You should add the flag --terragrunt-include-external-dependencies to the plan command:

    terragrunt run-all plan --terragrunt-include-external-dependencies