Skip to content

About

TFLint ruleset template

Topics

Resources

Stars

45 stars

Watchers

4 watching

Forks

Latest commit

 

History

184 Commits

Folders and files

Repository files navigation

TFLint Ruleset Template

Build Status

This is a template repository for building a custom ruleset. You can create a plugin repository from "Use this template". See also Writing Plugins.

Requirements

  • TFLint v0.46+

Installation

TODO: This template repository does not contain release binaries, so this installation will not work. Please rewrite for your repository. See the "Building the plugin" section to get this template ruleset working.

You can install the plugin with tflint --init. Declare a config in .tflint.hcl as follows:

plugin "template" {
  enabled = true

  version = "0.1.0"
  source  = "github.com/terraform-linters/tflint-ruleset-template"
}

Rules

Name Description Severity Enabled Link
aws_instance_example_type Example rule for accessing and evaluating top-level attributes ERROR ✔
aws_s3_bucket_example_lifecycle_rule Example rule for accessing top-level/nested blocks and attributes under the blocks ERROR ✔
google_compute_ssl_policy Example rule with a custom rule config WARNING ✔
terraform_backend_type Example rule for accessing other than resources ERROR ✔

Building the plugin

Clone the repository locally and run the following command:

$ make

You can easily install the built plugin with the following:

$ make install

You can run the built plugin like the following:

$ cat << EOS > .tflint.hcl
plugin "template" {
  enabled = true
}
EOS
$ tflint

About

TFLint ruleset template

Topics

Resources

Stars

45 stars

Watchers

4 watching

Forks

Releases

Packages

Used by

Contributors

Languages