Skip to main content
The terragrunt run-all command lets you perform bulk Terraform operations—such as init, plan, apply, and destroy—across every module in your project. By automating multi-module workflows, it reduces manual effort and ensures consistency in large-scale Terraform deployments.
The image is an infographic about "Terragrunt run-all," highlighting its support for Terragrunt commands like init, plan, apply, and destroy, and its capability for bulk execution.

Key Features

The image illustrates the concept of "Terragrunt run-all" with colorful puzzle piece icons and emphasizes workflow streamlining by reducing manual command execution.
The image illustrates the concept of "Terragrunt run-all" with icons representing parallel execution of tasks. It features colorful puzzle piece icons and a label indicating "Parallel Execution."

Common Use Cases

  • Apply changes across all modules with a single command
  • Destroy resources uniformly in every module
  • Automate routine Terraform tasks in CI/CD pipelines
The image is a presentation slide about "Terragrunt run-all," highlighting benefits such as performing the same operations across modules and saving time and effort. It includes icons and a "Use Cases" button.

Best Practices

  • Review your Terraform plans before applying changes.
  • Use targeted execution (--terragrunt-include-dir / --terragrunt-exclude-dir) to scope large projects.
  • Remember that run-all apply and run-all destroy add --auto-approve by default.
When running terragrunt run-all apply or terragrunt run-all destroy, Terragrunt automatically appends --auto-approve. Ensure you understand the full impact before executing these commands.
The image is an infographic about "Terragrunt run-all," highlighting its use for consistent and automated operations and its ability to reduce human error, with a "Best Practices" label.

Example: Applying Multiple VPC Modules

Assume you have two directories—vpc-1 and vpc-2—each containing a terragrunt.hcl that sources the AWS VPC module:
From the parent directory, list modules:
  1. Initialize all modules
    Downloads providers, creates cache folders, and writes lock files in each module.
  2. Plan and apply changes
    Prompts once, then creates VPCs in both modules:
  3. Destroy all resources
    Confirm with yes to tear down everything:

References

Watch Video