Vulnerability #17
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
| name: Vulnerability | |
| permissions: | |
| contents: read | |
| id-token: write | |
| on: | |
| push: | |
| branches: | |
| - main | |
| pull_request: | |
| schedule: # Mondays at 04:00 UTC | |
| - cron: '0 4 * * Mon' | |
| jobs: | |
| govulncheck: | |
| runs-on: ubuntu-latest | |
| env: | |
| GOPROXY: https://${{ secrets.GOPROXY }},direct | |
| GONOSUMDB: ${{ secrets.GONOSUMDB }} | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v6 | |
| - name: Setup Proxy Credentials | |
| uses: extractions/netrc@v2 | |
| with: | |
| machine: ${{ secrets.GOPROXY }} | |
| username: ${{ secrets.GOPROXY_USERNAME }} | |
| password: ${{ secrets.GOPROXY_TOKEN }} | |
| - name: Install Go | |
| if: success() | |
| uses: actions/setup-go@v5 | |
| with: | |
| go-version-file: 'go.mod' | |
| - name: Download dependencies | |
| run: go mod download | |
| if: steps.install-go.outputs.cache-hit != 'true' | |
| - name: Run govalncheck | |
| run: | | |
| go run golang.org/x/vuln/cmd/govulncheck@latest ./... |