docs/src/data/flags/find-exclude.mdx
Include exclude configuration in the output. When enabled, the JSON output will include the configurations of the exclude block in the discovered units.
--exclude
Show exclude configurations in JSON format:
terragrunt find --exclude --format=json
Show exclude configurations with queue construct simulation:
terragrunt find --exclude --queue-construct-as=plan --format=json
When enabled, the JSON output will include any exclude block configurations found in the units:
$ terragrunt find --exclude --format=json | jq
[
{
"type": "unit",
"path": "action/exclude-apply",
"exclude": {
"exclude_dependencies": true,
"actions": [
"apply"
],
"if": true
}
},
{
"type": "unit",
"path": "action/exclude-plan",
"exclude": {
"exclude_dependencies": true,
"actions": [
"plan"
],
"if": true
}
},
{
"type": "unit",
"path": "all-except-output/app1",
"exclude": {
"exclude_dependencies": true,
"actions": [
"all_except_output"
],
"if": true
}
}
]
Note that you can combine this with the --queue-construct-as flag to dry-run behavior relevant to excludes.
$ terragrunt find --exclude --queue-construct-as=plan --format=json | jq
[
{
"type": "unit",
"path": "action/exclude-apply",
"exclude": {
"exclude_dependencies": true,
"actions": [
"apply"
],
"if": true
}
}
]