Skip to content

Snyk Security Scan

Snyk Security Scan #72

Workflow file for this run

name: Snyk Security Scan
on:
push:
branches: [main, dev, 'release/*']
pull_request:
branches: [main, dev, 'release/*']
jobs:
# # Snyk Security Scan : scan for vulnerabilities and create a SARIF file
# security:
# runs-on: ubuntu-latest
# if: github.event_name == 'push'
# steps:
# - uses: actions/checkout@master
# - name: Install dependencies
# run: npm install
# - name: Run Snyk to check for vulnerabilities
# uses: snyk/actions/node@master
# continue-on-error: true # To make sure that SARIF upload gets called
# env:
# SNYK_TOKEN: ${{ secrets.SNYK_TOKEN }}
# with:
# args: --sarif-file-output=snyk.sarif
# - name: Upload result to GitHub Code Scanning
# uses: github/codeql-action/upload-sarif@v3
# with:
# sarif_file: snyk.sarif
# Block merge if vulnerabilities are found
merge_security:
runs-on: ubuntu-latest
if: github.event_name == 'pull_request'
steps:
- uses: actions/checkout@master
- name: Install dependencies
run: npm install
- name: Run Snyk to check for vulnerabilities
uses: snyk/actions/node@master
env:
SNYK_TOKEN: ${{ secrets.SNYK_TOKEN }}
with:
args: --severity-threshold=high --fail-on=high