You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
*[`checkov`](https://github.com/bridgecrewio/checkov) required for `terraform_checkov` hook
77
78
*[`terraform-docs`](https://github.com/terraform-docs/terraform-docs) required for `terraform_docs` hook
78
-
*[`terragrunt`](https://terragrunt.gruntwork.io/docs/getting-started/install/) required for `terragrunt_validate`hook
79
+
*[`terragrunt`](https://terragrunt.gruntwork.io/docs/getting-started/install/) required for `terragrunt_validate`and `terragrunt_valid_inputs` hooks
79
80
*[`terrascan`](https://github.com/tenable/terrascan) required for `terrascan` hook
80
81
*[`TFLint`](https://github.com/terraform-linters/tflint) required for `terraform_tflint` hook
81
82
*[`TFSec`](https://github.com/liamg/tfsec) required for `terraform_tfsec` hook
@@ -295,6 +296,7 @@ There are several [pre-commit](https://pre-commit.com/) hooks to keep Terraform
295
296
|`terraform_validate`| Validates all Terraform configuration files. [Hook notes](#terraform_validate)|`jq`, only for `--retry-once-with-cleanup` flag |
296
297
|`terragrunt_fmt`| Reformat all [Terragrunt](https://github.com/gruntwork-io/terragrunt) configuration files (`*.hcl`) to a canonical format. |`terragrunt`|
297
298
|`terragrunt_validate`| Validates all [Terragrunt](https://github.com/gruntwork-io/terragrunt) configuration files (`*.hcl`) |`terragrunt`|
299
+
| `terragrunt_validate_inputs` | Validates [Terragrunt](https://github.com/gruntwork-io/terragrunt) unused and undefined inputs (`*.hcl`)
298
300
|`terragrunt_providers_lock`| Generates `.terraform.lock.hcl` files using [Terragrunt](https://github.com/gruntwork-io/terragrunt). |`terragrunt`|
299
301
|`terraform_wrapper_module_for_each`| Generates Terraform wrappers with `for_each` in module. [Hook notes](#terraform_wrapper_module_for_each)|`hcledit`|
300
302
|`terrascan`|[terrascan](https://github.com/tenable/terrascan) Detect compliance and security violations. [Hook notes](#terrascan)|`terrascan`|
@@ -1121,6 +1123,28 @@ It invokes `terragrunt providers lock` under the hood and terragrunt [does its'
1121
1123
- --args=-platform=linux_amd64
1122
1124
```
1123
1125
1126
+
### terragrunt_validate_inputs
1127
+
1128
+
Validates Terragrunt unused and undefined inputs. This is useful for keeping
1129
+
configs clean when module versions change or if configs are copied.
1130
+
1131
+
See the [Terragrunt docs](https://terragrunt.gruntwork.io/docs/reference/cli-options/#validate-inputs) for more details.
1132
+
1133
+
Example:
1134
+
1135
+
```yaml
1136
+
- id: terragrunt_validate_inputs
1137
+
name: Terragrunt validate inputs
1138
+
args:
1139
+
# Optionally check for unused inputs
1140
+
- --args=--terragrunt-strict-validate
1141
+
```
1142
+
1143
+
> [!NOTE]
1144
+
> This hook requires authentication to a given account if defined by config to work properly. For example, if you use a third-party tool to store AWS credentials like `aws-vault` you must be authenticated first.
1145
+
>
1146
+
> See docs for the [iam_role](https://terragrunt.gruntwork.io/docs/reference/config-blocks-and-attributes/#iam_role) attribute and [--terragrunt-iam-role](https://terragrunt.gruntwork.io/docs/reference/cli-options/#terragrunt-iam-role) flag for more.
0 commit comments