Skip to content

Merge pull request #104 from MorpheusAIs/ryanleung-build #11

Merge pull request #104 from MorpheusAIs/ryanleung-build

Merge pull request #104 from MorpheusAIs/ryanleung-build #11

Workflow file for this run

name: Security Scan
permissions:
security-events: write
contents: write
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
security_scan:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.x'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
pip install safety bandit
- name: Run Safety check
run: safety check -r requirements.txt
continue-on-error: true
- name: Run Bandit
run: bandit -r . -f custom
continue-on-error: true
- name: Run Trivy vulnerability scanner
uses: aquasecurity/[email protected]
with:
scan-type: 'fs'
ignore-unfixed: true
format: 'sarif'
output: 'trivy-results.sarif'
severity: 'CRITICAL'
- name: Upload Trivy scan results
uses: github/codeql-action/upload-sarif@v3
with:
sarif_file: 'trivy-results.sarif'