celary tests working #4
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Security Scan | |
| on: | |
| push: | |
| branches: [ main, master, develop ] | |
| pull_request: | |
| branches: [ main, master, develop ] | |
| schedule: | |
| - cron: '0 0 * * 0' # Run weekly on Sunday at midnight | |
| jobs: | |
| dependency-check: | |
| name: OWASP Dependency Check | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v3 | |
| - name: Set up Python | |
| uses: actions/setup-python@v4 | |
| with: | |
| python-version: '3.11' | |
| - name: Install dependencies | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install safety | |
| pip install -r requirements.txt | |
| - name: Run Safety Check | |
| run: safety check -r requirements.txt --full-report --output text | |
| - name: Run OWASP Dependency-Check | |
| uses: dependency-check/Dependency-Check_Action@main | |
| with: | |
| project: 'django-supabase-template' | |
| path: '.' | |
| format: 'HTML' | |
| out: 'reports' | |
| args: > | |
| --enableExperimental | |
| --scan requirements.txt | |
| - name: Upload Dependency Check Report | |
| uses: actions/upload-artifact@v3 | |
| with: | |
| name: dependency-check-report | |
| path: reports/ | |
| bandit-scan: | |
| name: Bandit Security Scan | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v3 | |
| - name: Set up Python | |
| uses: actions/setup-python@v4 | |
| with: | |
| python-version: '3.11' | |
| - name: Install dependencies | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install bandit | |
| - name: Run Bandit | |
| run: bandit -r backend/ -f json -o bandit-results.json | |
| - name: Upload Bandit Results | |
| uses: actions/upload-artifact@v3 | |
| with: | |
| name: bandit-results | |
| path: bandit-results.json |