update versions etc #30
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Tflint Checks on Terraform Code | |
on: | |
push: | |
branches: | |
- main | |
permissions: read-all | |
jobs: | |
tflint-checks: | |
runs-on: ubuntu-latest | |
steps: | |
# Checkout Repository | |
- name : Check out Git Repository | |
uses: actions/checkout@v4 | |
# TFLint - Terraform Check | |
- 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 | |
with: | |
github_token: ${{ secrets.CI_GITHUB_TOKEN }} | |
# Print TFLint version | |
- name: Show version | |
run: tflint --version | |
# Install plugins | |
- name: Init TFLint | |
run: tflint --init | |
# Run tflint command in each directory recursively # use --force if you want to continue with workflow although errors are there | |
- name: Run TFLint | |
run: tflint -f compact --recursive |