From 5e1be2ab403222e87d3f361ba25f149c78460dd4 Mon Sep 17 00:00:00 2001 From: kp-aldo-pedromingo <108072074+kp-aldo-pedromingo@users.noreply.github.com> Date: Thu, 6 Jun 2024 17:08:50 +0200 Subject: [PATCH] PIA-1914: Add semgrep static analyzer to CI (#13) --- .github/workflows/semgrep.yaml | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 .github/workflows/semgrep.yaml diff --git a/.github/workflows/semgrep.yaml b/.github/workflows/semgrep.yaml new file mode 100644 index 0000000..9a7b04e --- /dev/null +++ b/.github/workflows/semgrep.yaml @@ -0,0 +1,29 @@ +name: Security / Semgrep + +on: + pull_request: + push: + branches: + - master + +jobs: + semgrep: + name: Security / Semgrep + runs-on: ubuntu-latest + container: + image: semgrep/semgrep:1.68.0 + if: (github.actor != 'dependabot[bot]') + steps: + - name: Checkout source repository + uses: actions/checkout@v4 + - name: Scan with Semgrep + env: + # Connect to Semgrep Cloud Platform + SEMGREP_APP_TOKEN: ${{ secrets.SEMGREP_APP_TOKEN }} + run: | + semgrep ci \ + --code \ + --secrets \ + --supply-chain \ + --pro \ + --no-suppress-errors \ No newline at end of file