ci: add gitleaks secret-scan job to ci.yml - #128
Conversation
Adds the required secret-scan job per the push-protection standard (petry-projects/.github/standards/push-protection.md#required-ci-job). Scans full git history on every PR and push to main using gitleaks v2.3.9, with --redact to prevent secrets appearing in logs and --exit-code 1 to fail the build on any finding. Closes #112 Co-authored-by: don-petry <don-petry@users.noreply.github.com>
|
Warning Rate limit exceeded
You’ve run out of usage credits. Purchase more in the billing tab. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
@don-petry This PR adds the required |
There was a problem hiding this comment.
Pull request overview
Adds a required gitleaks-based secret scanning job to the main CI workflow to satisfy the push-protection compliance check (Issue #112), running on pushes and PRs to main and scanning full git history.
Changes:
- Add a new
secret-scanjob to.github/workflows/ci.ymlusinggitleaks/gitleaks-actionpinned by SHA. - Configure checkout with
fetch-depth: 0and rungitleaks detectwith--redactand--exit-code 1.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| # Pin to SHA per Action Pinning Policy (ci-standards.md#action-pinning-policy). | ||
| # Look up current SHA: gh api repos/actions/checkout/git/refs/tags/v4 --jq '.object.sha' | ||
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | ||
| with: | ||
| fetch-depth: 0 | ||
|
|
||
| - name: Run gitleaks | ||
| # Pinned to SHA per Action Pinning Policy (ci-standards.md#action-pinning-policy). |
There was a problem hiding this comment.
This comment references ci-standards.md#action-pinning-policy, but there’s no ci-standards.md in this repo. Please update it to an existing doc/location (or remove). Also, the “Look up current SHA” command points at actions/checkout tag v4, which doesn’t match the version comment on the pinned SHA here—align the lookup command with the version/tag you intend to track.
| # Pin to SHA per Action Pinning Policy (ci-standards.md#action-pinning-policy). | |
| # Look up current SHA: gh api repos/actions/checkout/git/refs/tags/v4 --jq '.object.sha' | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| with: | |
| fetch-depth: 0 | |
| - name: Run gitleaks | |
| # Pinned to SHA per Action Pinning Policy (ci-standards.md#action-pinning-policy). | |
| # Pinned to a commit SHA for supply-chain safety. | |
| # Look up current SHA: gh api repos/actions/checkout/git/refs/tags/v6.0.2 --jq '.object.sha' | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| with: | |
| fetch-depth: 0 | |
| - name: Run gitleaks | |
| # Pinned to a commit SHA for supply-chain safety. |
|
|
||
| - name: Run gitleaks | ||
| # Pinned to SHA per Action Pinning Policy (ci-standards.md#action-pinning-policy). | ||
| # Refresh with: gh api repos/gitleaks/gitleaks-action/git/refs/tags/v2 --jq '.object.sha' |
There was a problem hiding this comment.
The “Refresh with” command references refs/tags/v2, but the pinned action comment indicates v2.3.9. To avoid accidentally resolving a different tag/commit in the future, update the command (or the comment) so it points at the exact tag/version you expect to pin (e.g., refs/tags/v2.3.9, then dereference if annotated).
| # Refresh with: gh api repos/gitleaks/gitleaks-action/git/refs/tags/v2 --jq '.object.sha' | |
| # Refresh with: gh api repos/gitleaks/gitleaks-action/git/refs/tags/v2.3.9 --jq '.object.sha' |
Outdated review (superseded by re-review at
|
|
Auto-rebase blocked — the base branch contains Please rebase this branch manually: |
The gitleaks/gitleaks-action requires a paid license for GitHub org repos. Switch to direct CLI install via wget + sha256 verification instead.
|
CI fix: replaced The
Also removed the now-unnecessary |
|
|
@claude Please address all open review comments on this PR from CodeRabbit and Copilot. |
|
Claude finished @don-petry's task in 2m 1s —— View job Review comment analysis complete
Finding: All Copilot review issues are already resolvedAfter reading the current
One remaining action needed (manual)The branch is 1 commit behind git fetch origin
git rebase origin/main
git push --force-with-lease
Suggested follow-up (no code change needed)The two Copilot inline review threads (comment IDs 3079440360 and 3079440452) may still appear as "Unresolved" in the GitHub UI even though the underlying code was fixed. Please resolve those threads manually after the rebase to keep the PR clean. |
|
@dev-lead - please fix this PR |
Dev-Lead Fix CI — failedPR: #128 | SHA: |
Dev-Lead Fix CI — failedPR: #128 | SHA: |
Dev-Lead Fix CI — exhaustedThis PR has had 2 consecutive engine failures (timeouts or errors). Automated CI fixing has been paused to avoid consuming further tokens. Reason for last failure: Engine invocation failed (exit 41) To re-enable, delete this comment or push a new commit with a substantially different change. |
|
|
Auto-rebase failed — merge conflict — this branch has conflicts with dev-lead will attempt to resolve this automatically. If it cannot, a follow-up comment will explain what needs manual attention. To resolve manually instead: |
|
Auto-rebase failed — merge conflict — this branch has conflicts with dev-lead will attempt to resolve this automatically. If it cannot, a follow-up comment will explain what needs manual attention. To resolve manually instead: |
|
Auto-rebase failed — merge conflict — this branch has conflicts with dev-lead will attempt to resolve this automatically. If it cannot, a follow-up comment will explain what needs manual attention. To resolve manually instead: |
|
Auto-rebase failed — merge conflict — this branch has conflicts with dev-lead will attempt to resolve this automatically. If it cannot, a follow-up comment will explain what needs manual attention. To resolve manually instead: |
|
Auto-rebase failed — merge conflict — this branch has conflicts with dev-lead will attempt to resolve this automatically. If it cannot, a follow-up comment will explain what needs manual attention. To resolve manually instead: |
|
Auto-rebase failed — merge conflict — this branch has conflicts with dev-lead will attempt to resolve this automatically. If it cannot, a follow-up comment will explain what needs manual attention. To resolve manually instead: |
|
Auto-rebase failed — merge conflict — this branch has conflicts with dev-lead will attempt to resolve this automatically. If it cannot, a follow-up comment will explain what needs manual attention. To resolve manually instead: |
|
Auto-rebase failed — merge conflict — this branch has conflicts with dev-lead will attempt to resolve this automatically. If it cannot, a follow-up comment will explain what needs manual attention. To resolve manually instead: |
|
Closing due to merge conflict that cannot be auto-rebased. Re-implementing from fresh main via dev-lead. |
Pull request was closed


Summary
secret-scanjob toci.ymlper the push-protection standardgitleaks/gitleaks-action@ff98106e4c7b2bc287b24eaf42907196329070c7(v2.3.9, SHA verified)fetch-depth: 0) on every PR and push tomain--redactprevents secrets from appearing in workflow logs--exit-code 1fails the build on any findingCloses #112
Generated with Claude Code