File tree Expand file tree Collapse file tree 2 files changed +16
-69
lines changed Expand file tree Collapse file tree 2 files changed +16
-69
lines changed Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1- name : Main Checks
1+ name : TFLint Checks
22
33on :
44 push :
5+ pull_request :
56 branches :
67 - main
78
89permissions :
910 contents : read
10- security-events : write
1111
1212jobs :
1313 lint :
1414 runs-on : ubuntu-latest
15- env :
16- # Required to avoid rate limiting when downloading plugins.
17- GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
1815 steps :
1916 - name : Checkout source code
2017 uses : actions/checkout@v4
21- - uses : actions/cache@v4
22- name : Cache plugin directory
18+ - name : Check security features
19+ id : security-features
20+ uses : ./.github/actions/security-features
21+ - name : Cache plugin directory
22+ uses : actions/cache@v4
2323 with :
2424 path : ~/.tflint.d/plugins
2525 key : tflint-${{ hashFiles('.tflint.hcl') }}
3131 run : tflint --init
3232 - name : Run TFLint
3333 run : tflint --format sarif --recursive --config "$GITHUB_WORKSPACE/.tflint.hcl" > tflint-results.sarif
34- - name : Upload SARIF result
34+ - name : Parse SARIF file for annotations
3535 if : always()
36+ 37+ with :
38+ severity-level : low
39+ sarif-file : tflint-results.sarif
40+ # When run on main, if SARIF uploads are available, we want to upload the
41+ # SARIF file to GitHub.
42+ - name : Upload SARIF result
43+ if : always() && github.ref == 'refs/heads/main' && steps.security-features.outputs.sarif == 'true'
3644 uses : github/codeql-action/upload-sarif@v3
3745 with :
3846 sarif_file : tflint-results.sarif
You can’t perform that action at this time.
0 commit comments