docs/src/data/flags/out-dir.mdx
import { Aside } from '@astrojs/starlight/components';
<Aside type="note">This flag only does anything when used with the --all flag for stack runs. It does nothing in single-unit runs.
To generate plan files for a single unit run, use the standard OpenTofu/Terraform -out flag like so:
terragrunt run -- plan -out=/tmp/tfplan
Specifies where Terragrunt writes native OpenTofu/Terraform plan files for each unit when running stack operations.
tfplan.tfplan per unit.<out-dir>/<relative-unit-path>/tfplan.tfplan).Examples:
# Save plans for all units under /tmp/tfplan
terragrunt run --all plan --out-dir /tmp/tfplan
# Apply using the previously generated plans (per-unit paths are inferred)
terragrunt run --all apply --out-dir /tmp/tfplan
See the Stacks docs for more usage examples.