Skip to content

👷 ci: add snyk security scanning workflow #946

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 20 commits into from
Jun 4, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
c5f5cda
👷 ci: add snyk security scanning workflow
w3bdesign Jun 4, 2025
e314e19
👷 ci: fix node cache dependency order in snyk workflow
w3bdesign Jun 4, 2025
03d0e19
🔧 chore(ci): update pnpm version specification in Snyk workflow
w3bdesign Jun 4, 2025
c50c137
📦 deps: upgrade pnpm action to v4 and use version 9
w3bdesign Jun 4, 2025
0e13832
👷 ci: comment out continue-on-error in Snyk action
w3bdesign Jun 4, 2025
8ad64c3
👷 ci: enhance Snyk scan configuration with org ID and studio deps
w3bdesign Jun 4, 2025
e30c521
📦 deps: update dependencies
w3bdesign Jun 4, 2025
1b77b34
🔧 chore(ci): remove explicit org ID from Snyk workflow
w3bdesign Jun 4, 2025
5f50f66
👷 ci: update snyk security scan workflow
w3bdesign Jun 4, 2025
dd2e8ed
🔧 chore(ci): remove redundant comment from snyk-scan workflow
w3bdesign Jun 4, 2025
91ed6f2
🔒 security: enhance snyk scan workflow with SARIF reporting
w3bdesign Jun 4, 2025
972cb3e
📦 deps: add ejs template engine
w3bdesign Jun 4, 2025
308d4a9
📦 deps: update dependencies
w3bdesign Jun 4, 2025
454653e
📦 deps: add ejs template engine dependency
w3bdesign Jun 4, 2025
3e89f1f
📦 deps: update dependencies
w3bdesign Jun 4, 2025
c480356
📦 deps: update dependencies
w3bdesign Jun 4, 2025
27cb212
🔥 cleanup: remove unused ejs dependency
w3bdesign Jun 4, 2025
f87815a
📦 deps: update dependencies
w3bdesign Jun 4, 2025
c394ef0
🔥 cleanup: remove comments from snyk-scan workflow
w3bdesign Jun 4, 2025
e83e80a
🔒 security: add Snyk security vulnerability scanning
w3bdesign Jun 4, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
62 changes: 62 additions & 0 deletions .github/workflows/snyk-scan.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
name: Snyk Security Scan

on:
push:
branches:
- main
pull_request:
branches:
- main

permissions:
contents: read
pull-requests: write
security-events: write

jobs:
snyk_scan:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 9

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: "20.x"
cache: "pnpm"

- name: Install dependencies
run: pnpm install --frozen-lockfile

- name: Install dependencies for studio
run: cd studio && pnpm install --frozen-lockfile && cd ..

- name: Run Snyk to check for vulnerabilities
uses: snyk/actions/node@master

env:
SNYK_TOKEN: ${{ secrets.SNYK_TOKEN }}
with:
command: "test"
args: "--all-projects --sarif-file-output=snyk.sarif --severity-threshold=high"

- name: Upload Snyk SARIF report to GitHub Security tab
if: always()
uses: github/codeql-action/upload-sarif@v3
with:
sarif_file: snyk.sarif

- name: Snyk Monitor (only for pushes to main branch)
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
uses: snyk/actions/node@master
env:
SNYK_TOKEN: ${{ secrets.SNYK_TOKEN }}
with:
command: "monitor"
args: "--all-projects"
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,9 @@ Sanity.io and Typescript.
- Automated PR analysis with repository structure insights
- Security-focused documentation with sensitive information filtering
- Markdown formatting for improved readability
- Automated security vulnerability scanning with Snyk
- Scans for vulnerabilities in open-source dependencies on every PR and push to main
- Integrates with GitHub Security tab for vulnerability tracking

### Environment Variables

Expand Down
Loading