gitleaks / gitleaks/gitleaks-action
Help with exit-code
- Dominant language
- JavaScript
- Stars
- 644
- Forks
- 194
- PR merge metrics
- No merged PRs in 30d
Description
Hi, I am using the below workflow which works fine for our use case but, i need the --exit-code to be set to 0 as we don't want to fail the scan or block the PR at the moment, and the scan to succeed.
```
name: gitleaks
on:
pull_request:
branches:
- main
jobs:
scan:
name: gitleaks-try-1
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: gitleaks/gitleaks-action@v2
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GITLEAKS_LICENSE: ${{ secrets.GITLEAKS_LICENSE}}
GITLEAKS_CONFIG: ${{ github.workspace }}/.github/gitleaks.toml
GITLEAKS_EXIT_CODE: 0
```
I checked online on how to pass arguments, but the results were that we cannot do so when we use gitleaks/gitleaks-action@v2 directly.
Kindly help on how to pass the --exit-code=0
Thanks
Contributor guide
Research direction
Start with the workflow shown in the issue and the configuration options for gitleaks/gitleaks-action@v2, focusing on how action inputs or environment variables reach the scan command. Done means the scan still runs while an exit code of 0 prevents the workflow and pull request from failing.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- github-actions
- Domain
- ci-cd, security
- Issue type
- Bug
- Difficulty
- 1/5
- Estimated time
- Under an hour
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100