Skip to content

Commit

Permalink
Initial release
Browse files Browse the repository at this point in the history
  • Loading branch information
Monska85 committed May 9, 2024
0 parents commit 7be8854
Show file tree
Hide file tree
Showing 17 changed files with 1,504 additions and 0 deletions.
37 changes: 37 additions & 0 deletions .github/workflows/tflint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: Lint

on:
push:
branches: [main]
pull_request:
types: [opened, synchronize]

jobs:
tflint:
runs-on: ${{ matrix.os }}

strategy:
matrix:
os: [ubuntu-latest]

steps:
- uses: actions/checkout@v4
name: Checkout source code

- uses: actions/cache@v4
name: Cache plugin dir
with:
path: ~/.tflint.d/plugins
key: ${{ matrix.os }}-tflint-${{ hashFiles('.tflint.hcl') }}

- uses: terraform-linters/setup-tflint@v4
name: Setup TFLint

- name: Show version
run: tflint --version

- name: Init TFLint
run: tflint --init

- name: Run TFLint
run: tflint -f compact
26 changes: 26 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# Local .terraform directories
**/.terraform/*
.terraform.lock.hcl

# .tfstate files
*.tfstate
*.tfstate.*

# Crash log files
crash.log

# IDE files
.idea

# Ignore any .tfvars files that are generated automatically for each Terraform run. Most
# .tfvars files are managed as part of configuration and so should be included in
# version control.
#
# example.tfvars

# Ignore override files as they are usually used to override resources locally and so
# are not checked in
override.tf
override.tf.json
*_override.tf
*_override.tf.json
61 changes: 61 additions & 0 deletions .terraform-docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
# Refs: https://github.com/terraform-docs/terraform-docs
formatter: "" # this is required

version: ""

header-from: main.tf
footer-from: ""

recursive:
enabled: false
path: modules

sections:
hide: []
show: []

content: |-
{{ .Providers }}
{{ .Requirements }}
{{ .Inputs }}
{{ .Outputs }}
{{ .Resources }}
{{ .Modules }}
{{ .Footer }}
output:
file: ""
mode: inject
template: |-
<!-- BEGIN_TF_DOCS -->
{{ .Content }}
<!-- END_TF_DOCS -->
output-values:
enabled: false
from: ""

sort:
enabled: true
by: name

settings:
anchor: true
color: true
default: true
description: false
escape: true
hide-empty: false
html: true
indent: 2
lockfile: true
read-comments: true
required: true
sensitive: true
type: true
39 changes: 39 additions & 0 deletions .tflint.hcl
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
config {
varfile = ["examples/test.tfvars"]
}

rule "terraform_unused_declarations" {
enabled = true
}

rule "terraform_comment_syntax" {
enabled = true
}

rule "terraform_deprecated_index" {
enabled = true
}

rule "terraform_deprecated_interpolation" {
enabled = true
}

rule "terraform_module_pinned_source" {
enabled = true
}

rule "terraform_naming_convention" {
enabled = true
}

rule "terraform_standard_module_structure" {
enabled = true
}

rule "terraform_typed_variables" {
enabled = true
}

rule "terraform_unused_required_providers" {
enabled = true
}
13 changes: 13 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# Changelog

All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
and this project adheres
to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [Unreleased]

## [0.1.0] - 2024-05-09

- First release.
Loading

0 comments on commit 7be8854

Please sign in to comment.