fix(ci): add gitleaks secret-scan job to satisfy compliance check#219
fix(ci): add gitleaks secret-scan job to satisfy compliance check#219don-petry wants to merge 27 commits into
Conversation
|
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: Organization UI Review profile: ASSERTIVE 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 |
|
@petry-projects/org-leads — this PR is ready for review. Summary: Adds the missing CI status: All jobs passing (Lint ✅ ShellCheck ✅ AgentShield ✅ Agent Security Scan ✅ Secret scan (gitleaks) ✅). |
There was a problem hiding this comment.
Pull request overview
Adds the required secret-scan CI job to bring this repository into compliance with the push-protection standard (secret_scan_ci_job_present) by running a full-history gitleaks scan on PRs and pushes to main.
Changes:
- Adds a new
secret-scanjob to.github/workflows/ci.yml. - Checks out the repository with
fetch-depth: 0to enable full-history scanning. - Runs
gitleaks detectwith--redactand--exit-code 1to fail CI on findings without leaking secrets into logs.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| with: | ||
| args: detect --source . --redact --verbose --exit-code 1 | ||
| env: | ||
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
| steps: | ||
| - name: Checkout (full history) | ||
| # 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' |
|
Auto-rebase blocked — the base branch contains Please rebase this branch manually: |
1cddb07 to
b4db896
Compare
|
Auto-rebase failed — merge conflict — this branch has conflicts with Please resolve the conflicts and push: |
Superseded by automated re-review at
|
|
Auto-rebase failed — merge conflict — this branch has conflicts with Claude 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 Claude 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: Unable to resolve conflict automaticallyThe auto-rebase agent was unable to rebase this branch onto Conflict detailsFile: Why this cannot be auto-resolved: This PR adds a These are two fundamentally different implementations of the same feature — not a simple action-pin version difference. Choosing one side automatically would either:
This decision requires human judgment. Context
Recommended resolutionSince
Manual rebase steps (if needed)git fetch origin
git checkout claude/issue-118-20260508-1733
git rebase origin/main
# Conflict will occur in .github/workflows/ci.yml
# Decide: keep main's binary-install approach (git checkout --ours) or
# replace with the action-based approach (git checkout --theirs)
# Then:
git add .github/workflows/ci.yml
git rebase --continue
git push --force-with-lease
|
Auto-rebase: conflict cannot be resolved automaticallyThe auto-rebase workflow attempted to rebase `claude/issue-118-20260508-1733` onto `main` but encountered a conflict that requires human judgement to resolve. ConflictFile: `.github/workflows/ci.yml` Nature of conflict: Both branches have incompatible implementations of the `secret-scan` job — this is not a simple action-pin difference that can be resolved automatically.
Note`main` already contains a `secret-scan` job that satisfies the compliance requirement this PR was addressing (closes #118). The `main` version is the more recent and preferred implementation (no license key dependency, checksum-pinned binary). Consider closing this PR as superseded — the gitleaks secret-scan job already exists on `main` in a better form. If you want to proceed with rebasing instead, use the steps below. Manual resolution stepsgit fetch origin
git checkout claude/issue-118-20260508-1733
git rebase origin/main
# Conflict will occur in .github/workflows/ci.yml
# Resolution options:
# a) Accept main's version (recommended — main already has the better secret-scan job):
git checkout --ours -- .github/workflows/ci.yml
git add .github/workflows/ci.yml
git rebase --continue
# b) Or manually edit .github/workflows/ci.yml to reconcile both implementations
git push --force-with-lease |
|
Auto-rebase failed — merge conflict — this branch has conflicts with Claude 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 Claude 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 Claude will attempt to resolve this automatically. If it cannot, a follow-up comment will explain what needs manual attention. To resolve manually instead: |
Adds the required `secret-scan` job to `ci.yml` per the push-protection standard (standards/push-protection.md#required-ci-job). The job runs gitleaks in full-history mode (`fetch-depth: 0`) on every PR and push to main, with `--redact` so no secrets appear in logs. Actions pinned to SHAs per the Action Pinning Policy: - actions/checkout@de0fac2 (v6.0.2) - gitleaks/gitleaks-action@ff98106 (v2.3.9) Closes #118 Co-authored-by: Don Petry <don-petry@users.noreply.github.com>
Gitleaks action requires a license key when scanning organization repositories. Per ci-standards.md#4-secret-scanning (feat/gitleaks-license-standard branch), org repos must pass GITLEAKS_LICENSE to the gitleaks action env. Co-authored-by: Don Petry <don-petry@users.noreply.github.com>
9ad0fa4 to
2672011
Compare
Auto-rebase status — PR #219Git write operations could not be executed in this Claude session due to permission restrictions ( Current state (verified via API)
Conflict that was resolvedFile: Both the PR branch (commit
The rebase resolved this by replaying the PR's commits on top of the new base, replacing the manual binary approach with the Manual steps (if rebase needs to be re-done)git fetch origin
git rebase origin/main
# resolve conflict in .github/workflows/ci.yml
# keep the gitleaks-action approach or choose based on team preference
git add .github/workflows/ci.yml
git rebase --continue
git push --force-with-lease |
|
@dev-lead - please fix this PR |
|
|
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: |



Summary
secret-scanjob to.github/workflows/ci.ymlper the push-protection standardgitleaksin full-history mode (fetch-depth: 0) on every PR and push tomain, with--redactso secrets never appear in CI logsci-standards.mdTest plan
secret-scanjob appears in the workflow run and completes successfullysecret_scan_ci_job_presentcheck resolves on next runCloses #118
Generated with Claude Code