Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .github/workflows/osv-scanner-reusable-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ jobs:
git checkout $GITHUB_BASE_REF
git submodule update --recursive
- name: "Run scanner on existing code"
uses: google/osv-scanner-action/osv-scanner-action@b930bc956e1d83bea419e0f159e1575c2c2ea401 # v2.2.3
uses: google/osv-scanner-action/osv-scanner-action@d510e7d909b203e4aa41380fa1e74c20cad9fadf # v2.2.4
continue-on-error: true
with:
scan-args: |-
Expand All @@ -79,15 +79,15 @@ jobs:
git checkout -f $GITHUB_SHA
git submodule update --recursive
- name: "Run scanner on new code"
uses: google/osv-scanner-action/osv-scanner-action@b930bc956e1d83bea419e0f159e1575c2c2ea401 # v2.2.3
uses: google/osv-scanner-action/osv-scanner-action@d510e7d909b203e4aa41380fa1e74c20cad9fadf # v2.2.4
with:
scan-args: |-
--format=json
--output=${{ inputs.matrix-property }}new-results.json
${{ inputs.scan-args }}
continue-on-error: true
- name: "Run osv-scanner-reporter"
uses: google/osv-scanner-action/osv-reporter-action@b930bc956e1d83bea419e0f159e1575c2c2ea401 # v2.2.3
uses: google/osv-scanner-action/osv-reporter-action@d510e7d909b203e4aa41380fa1e74c20cad9fadf # v2.2.4
with:
scan-args: |-
--output=${{ inputs.matrix-property }}${{ inputs.results-file-name }}
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/osv-scanner-reusable.yml
Original file line number Diff line number Diff line change
Expand Up @@ -77,15 +77,15 @@ jobs:
name: "${{ inputs.download-artifact }}"
path: "./"
- name: "Run scanner"
uses: google/osv-scanner-action/osv-scanner-action@b930bc956e1d83bea419e0f159e1575c2c2ea401 # v2.2.3
uses: google/osv-scanner-action/osv-scanner-action@d510e7d909b203e4aa41380fa1e74c20cad9fadf # v2.2.4
with:
scan-args: |-
--output=${{ inputs.matrix-property }}results.json
--format=json
${{ inputs.scan-args }}
continue-on-error: true
- name: "Run osv-scanner-reporter"
uses: google/osv-scanner-action/osv-reporter-action@b930bc956e1d83bea419e0f159e1575c2c2ea401 # v2.2.3
uses: google/osv-scanner-action/osv-reporter-action@d510e7d909b203e4aa41380fa1e74c20cad9fadf # v2.2.4
with:
scan-args: |-
--output=${{ inputs.matrix-property }}${{ inputs.results-file-name }}
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/osv-scanner-unified-workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ permissions:
jobs:
scan-scheduled:
if: ${{ github.event_name == 'push' || github.event_name == 'schedule' }}
uses: "google/osv-scanner-action/.github/workflows/osv-scanner-reusable.yml@e16154965f9006f67889ca978f5bba09f51dc0fc" # v2.2.3
uses: "google/osv-scanner-action/.github/workflows/osv-scanner-reusable.yml@ef6f278161933625ae65a409a858a83c4934e3f2" # v2.2.4
with:
# Example of specifying custom arguments
scan-args: |-
Expand All @@ -44,7 +44,7 @@ jobs:
./
scan-pr:
if: ${{ github.event_name == 'pull_request' || github.event_name == 'merge_group' }}
uses: "google/osv-scanner-action/.github/workflows/osv-scanner-reusable-pr.yml@e16154965f9006f67889ca978f5bba09f51dc0fc" # v2.2.3
uses: "google/osv-scanner-action/.github/workflows/osv-scanner-reusable-pr.yml@ef6f278161933625ae65a409a858a83c4934e3f2" # v2.2.4
with:
# Example of specifying custom arguments
scan-args: |-
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# OSV-Scanner CI/CD Action

[![Release v2.2.3](https://img.shields.io/badge/release-v2.2.3-blue?style=flat)](https://github.com/google/osv-scanner-action/releases)
[![Release v2.2.4](https://img.shields.io/badge/release-v2.2.4-blue?style=flat)](https://github.com/google/osv-scanner-action/releases)
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

To avoid manually updating the version in the README for each release, you can use a dynamic badge from shields.io that automatically displays the latest GitHub release version. This would ensure the badge is always up-to-date without any manual intervention.

Suggested change
[![Release v2.2.4](https://img.shields.io/badge/release-v2.2.4-blue?style=flat)](https://github.com/google/osv-scanner-action/releases)
[![Release](https://img.shields.io/github/v/release/google/osv-scanner-action?style=flat)](https://github.com/google/osv-scanner-action/releases)

<!-- Hard coded release version -->

The OSV-Scanner CI/CD action leverages the [OSV.dev](https://osv.dev/) database and the [OSV-Scanner](https://google.github.io/osv-scanner/) CLI tool to track and notify you of known vulnerabilities in your dependencies for over 11 [languages and ecosystems](https://google.github.io/osv-scanner/supported-languages-and-lockfiles/).
Expand Down
2 changes: 1 addition & 1 deletion osv-reporter-action/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ inputs:
required: true
runs:
using: "docker"
image: "docker://ghcr.io/google/osv-scanner-action:v2.2.3"
image: "docker://ghcr.io/google/osv-scanner-action:v2.2.4"
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

The version string v2.2.4 is hardcoded here and in other files (osv-scanner-action/action.yml, README.md). Manually updating the version in multiple places is error-prone and can lead to inconsistencies if a location is missed. To improve maintainability, consider automating this process. A release script could read the version from a single source of truth (e.g., a version file or git tag) and use a tool to update all occurrences. This would make future releases more robust and less dependent on manual changes.

entrypoint: /root/osv-reporter
args:
- "${{ inputs.scan-args }}"
2 changes: 1 addition & 1 deletion osv-scanner-action/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,6 @@ inputs:
./
runs:
using: "docker"
image: "docker://ghcr.io/google/osv-scanner-action:v2.2.3"
image: "docker://ghcr.io/google/osv-scanner-action:v2.2.4"
args:
- ${{ inputs.scan-args }}