Skip to content

Commit 76ed4b8

Browse files
fix: try installing sbom tools different
1 parent 0e6fa06 commit 76ed4b8

File tree

1 file changed

+13
-13
lines changed

1 file changed

+13
-13
lines changed

.github/workflows/build.yml

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@ name: AIBomGen-cli Go Build
22

33
on:
44
push:
5-
branches: [ main ]
5+
branches: [main]
66
pull_request:
7-
branches: [ main ]
7+
branches: [main]
88

99
jobs:
1010
build:
@@ -14,7 +14,7 @@ jobs:
1414
runs-on: ubuntu-latest
1515
strategy:
1616
matrix:
17-
go-version: [ '1.25.x', '1.24.x', '1.23.x', '1.22.x', '1.21.x' ]
17+
go-version: ["1.25.x", "1.24.x", "1.23.x", "1.22.x", "1.21.x"]
1818
steps:
1919
- name: Checkout code
2020
uses: actions/checkout@v4
@@ -58,15 +58,15 @@ jobs:
5858
run: |
5959
go build -o AIBoMGen-cli ./
6060
chmod +x AIBoMGen-cli
61-
- name: Install Syft, Grype and Cosign
62-
if: ${{ matrix.go-version == '1.25.x' }}
63-
run: |
64-
sudo apt-get update
65-
sudo apt-get install -y jq curl
66-
curl -sSfL https://raw.githubusercontent.com/anchore/syft/main/install.sh | sh -s -- -b /usr/local/bin
67-
curl -sSfL https://raw.githubusercontent.com/anchore/grype/main/install.sh | sh -s -- -b /usr/local/bin
68-
curl -sfL https://github.com/sigstore/cosign/releases/latest/download/cosign-linux-amd64 -o /usr/local/bin/cosign
69-
chmod +x /usr/local/bin/cosign
61+
62+
- name: Install Syft
63+
uses: anchore/sbom-action/[email protected]
64+
65+
- name: Install Cosign
66+
uses: sigstore/[email protected]
67+
68+
- name: Install Grype
69+
uses: anchore/scan-action/download-grype@v4
7070

7171
- name: Generate SBOM (Syft)
7272
if: ${{ matrix.go-version == '1.25.x' }}
@@ -103,4 +103,4 @@ jobs:
103103
path: |
104104
sbom-binary.json
105105
sbom-binary-vulnerabilities.json
106-
sbom.bundle.json
106+
sbom.bundle.json

0 commit comments

Comments
 (0)