Skip to content

Merge pull request #317 from arene-os-services-cockpit-tmc-wa/jw/oss-… #6

Merge pull request #317 from arene-os-services-cockpit-tmc-wa/jw/oss-…

Merge pull request #317 from arene-os-services-cockpit-tmc-wa/jw/oss-… #6

Workflow file for this run

---
name: IaC Misconfigurations scan
on: [push]
permissions:
contents: read
actions: read
id-token: write
security-events: write
jobs:
set-matrix:
runs-on: [self-hosted, default-k8s-runner-linux-x64]
outputs:
dockerfiles: ${{ steps.set-matrix.outputs.dockerfiles }}
steps:
- name: Check out repository
uses: actions/checkout@v3
- name: find-docker-files
id: set-matrix
run: |
dockerfiles=$(find . -name "Dockerfile" | jq --raw-input --slurp -c 'split("\n") | map(select(. != ""))')
echo "dockerfiles=${dockerfiles}" >> $GITHUB_OUTPUT
wiz-iac-scan-docker:
needs: set-matrix
runs-on: [self-hosted, default-k8s-runner-linux-x64]
if: ${{ needs.set-matrix.outputs.dockerfiles != '[]' && needs.set-matrix.outputs.dockerfiles != '' }}
strategy:
fail-fast: false
matrix:
dockerfile: ${{ fromJson(needs.set-matrix.outputs.dockerfiles) }}
steps:
- name: Check out repository
uses: actions/checkout@v3
- name: Wiz IaC Scan
uses: Innersource/wizcli-wrapper@v1
with:
skip_iac_scan: "skip"
docker_scan_filename: "${{ matrix.dockerfile }}"
wiz-iac-scan-default:
needs: set-matrix
runs-on: [self-hosted, default-k8s-runner-linux-x64]
steps:
- name: Check out repository
uses: actions/checkout@v3
- name: Wiz IaC Scan
uses: Innersource/wizcli-wrapper@v1
with:
iac_scan_path: "."
skip_docker_scan: "skip"