Phase 0 & Phase 1 Complete: Security fixes and quality improvements #1
Workflow file for this run
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, develop, claude/** ] | |
| pull_request: | |
| branches: [ main, develop ] | |
| schedule: | |
| # Run weekly security scan | |
| - cron: '0 0 * * 0' | |
| jobs: | |
| dependency-scan: | |
| name: Dependency Security Scan | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: '3.11' | |
| - name: Install dependencies | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install safety bandit | |
| - name: Run Safety check | |
| run: | | |
| pip install -r requirements.txt | |
| safety check --json --output safety-report.json || true | |
| - name: Run Bandit | |
| run: | | |
| bandit -r aiops/ -f json -o bandit-report.json || true | |
| - name: Upload Security Reports | |
| uses: actions/upload-artifact@v3 | |
| with: | |
| name: security-reports | |
| path: | | |
| safety-report.json | |
| bandit-report.json | |
| code-scan: | |
| name: Code Security Analysis | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Run Bandit Security Scan | |
| run: | | |
| pip install bandit | |
| bandit -r aiops/ -ll -i | |
| - name: Check for secrets | |
| uses: trufflesecurity/trufflehog@main | |
| with: | |
| path: ./ | |
| base: ${{ github.event.repository.default_branch }} | |
| head: HEAD |