Skip to content

update the Gitleaks guidance to use docker#375

Open
samia-nhse wants to merge 3 commits intomainfrom
sw-secret-scan
Open

update the Gitleaks guidance to use docker#375
samia-nhse wants to merge 3 commits intomainfrom
sw-secret-scan

Conversation

@samia-nhse
Copy link
Copy Markdown

No description provided.

@samia-nhse samia-nhse requested a review from a team as a code owner April 28, 2026 09:12
Comment thread tools/gitleaks.md Outdated
run: docker run --rm --platform linux/amd64 \
-v "$(pwd):/repo" \
-w /repo \
ghcr.io/gitleaks/gitleaks:v8.30.1 \
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would you mind considering pinning this image by digest rather than by tag and keeping the version as a comment for readability?

The current reference uses v8.30.1 but container tags are not immutable and can be retargeted, whereas a sha256 digest gives us a content-addressed, reviewable reference. That would also be consistent with the framework's preference for immutable pinning in actions-best-practices.md "Pin All Actions to a Commit SHA".

Perhaps somthing like this:

# gitleaks v8.30.1
docker run --rm --platform linux/amd64 \
  -v "$(pwd):/repo" \
  -w /repo \
  ghcr.io/gitleaks/gitleaks@sha256:c00b6bd0aeb3071cbcb79009cb16a60dd9e0a7c60e2be9ab65d25e6bc8abbb7f \
  git /repo --redact --verbose --log-opts="--all"

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

updated :)

samia-nhse added 2 commits May 7, 2026 11:43
Signed-off-by: Samia Wear <samia.wear1@nhs.net>
@sonarqubecloud
Copy link
Copy Markdown

sonarqubecloud Bot commented May 7, 2026

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants