> ## Documentation Index
> Fetch the complete documentation index at: https://docs.coderabbit.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# TFLint

> CodeRabbit's guide to TFLint.

[TFLint](https://github.com/terraform-linters/tflint) is a linter for Terraform configuration files.

## Files

TFLint runs only on files with the following extension:

* `.tf`

## Configuration

* If the repository does not include `.tflint.hcl`, CodeRabbit runs TFLint with its safe defaults.
* If the repository does include `.tflint.hcl`, CodeRabbit writes and uses a safe override config that enables only the bundled `terraform` ruleset.
* A repository `.tflint.hcl` is not required.

## Security policy and restrictions

* CodeRabbit recognizes the following plugin names as approved when inspecting `.tflint.hcl`.
  * **terraform** — bundled with TFLint ([tflint-ruleset-terraform](https://github.com/terraform-linters/tflint-ruleset-terraform))
  * **aws** — [tflint-ruleset-aws](https://github.com/terraform-linters/tflint-ruleset-aws)
  * **google** — [tflint-ruleset-google](https://github.com/terraform-linters/tflint-ruleset-google)
  * **azurerm** — [tflint-ruleset-azurerm](https://github.com/terraform-linters/tflint-ruleset-azurerm)

## When we skip TFLint

CodeRabbit skips TFLint when:

* TFLint is disabled in your CodeRabbit configuration.
* No `.tf` files are in the pull request.
* TFLint is already running in GitHub workflows.

## Links

* [TFLint GitHub Repository](https://github.com/terraform-linters/tflint)
* [TFLint Documentation](https://github.com/terraform-linters/tflint/tree/master/docs)
