constellation/.github/workflows/test-tfsec.yml
renovate[bot] f90e8fc35a
Update actions/checkout digest to 8230315 (#246)
Co-authored-by: Paul Meyer <49727155+katexochen@users.noreply.github.com>
2022-10-13 16:54:43 +02:00

43 lines
1.0 KiB
YAML

name: Terraform security scanner
on:
workflow_dispatch:
push:
branches:
- main
paths:
- "**.tf"
pull_request:
paths:
- "**.tf"
permissions:
contents: read
pull-requests: write
# Abort runs of *this* workflow, if a new commit with the same ref is pushed.
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}
jobs:
tfsec:
name: tfsec
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@8230315d06ad95c617244d2f265d237a1682d445
with:
ref: ${{ github.event.pull_request.head.sha }}
- name: tfsec
uses: aquasecurity/tfsec-pr-commenter-action@d9fa64305ec243e19f9be1200dfc8e8154dc364f
with:
tfsec_formats: default,text
tfsec_args: --force-all-dirs
github_token: ${{ github.token }}
- name: tfsec summary
shell: bash
run: cat results.text | tail -n 27 >> $GITHUB_STEP_SUMMARY