Skip to content

add govulncheck make target and github action for scanning vulnerabil… #14

add govulncheck make target and github action for scanning vulnerabil…

add govulncheck make target and github action for scanning vulnerabil… #14

Workflow file for this run

# Copyright (c) 2025, NVIDIA CORPORATION. All rights reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
name: Go Vulnerability Check
on:
push:
branches:
- main
- "pull-request/[0-9]+"
paths-ignore:
- '**/*.md'
- 'docs/**'
- 'LICENSE'
- '.github/ISSUE_TEMPLATE/**'
- '.github/headers/**'
tags:
- 'v*'
workflow_dispatch:
schedule:
- cron: '0 6 * * *'
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}
permissions:
contents: read
security-events: write
pull-requests: write
jobs:
govulncheck:
runs-on: ubuntu-latest
timeout-minutes: 30
permissions:
contents: read
security-events: write
steps:
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
- name: Setup Go
uses: actions/setup-go@44694675825211faa026b3c33043df3e48a5fa00 # v6.0.0
with:
go-version: 'stable'
- name: Install dependencies
run: |
go install golang.org/x/vuln/cmd/govulncheck@latest
sudo apt-get update && sudo apt-get install -y jq
- name: Run govulncheck on all Go modules
run: ./scripts/govulncheck-all.sh