secrets-scan #83
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
| # Gitleaks: robust secrets scanning of diffs and history. | |
| name: secrets-scan | |
| on: | |
| pull_request: | |
| branches: [ "main", "develop" ] | |
| push: | |
| branches: [ "main", "develop" ] | |
| schedule: | |
| - cron: "35 2 * * *" # daily | |
| permissions: | |
| contents: read | |
| security-events: write | |
| jobs: | |
| gitleaks: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| with: | |
| fetch-depth: 0 # scan full history on scheduled runs | |
| - name: Run Gitleaks | |
| uses: gitleaks/gitleaks-action@v2 | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| GITLEAKS_LICENSE: ${{ secrets.GITLEAKS_LICENSE }} # Only required for Organizations, not personal accounts. | |
| with: | |
| args: detect --source . --no-git=true --redact --report-format sarif --report-path gitleaks.sarif |