Skip to content

Commit

Permalink
Update SBOM workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
dragomirp committed Nov 27, 2023
1 parent aae0019 commit 528c498
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions .github/workflows/sbom.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,18 +15,17 @@ jobs:
- name: Install Syft
run: |
curl -sSfL https://raw.githubusercontent.com/anchore/syft/4fc17edd146af34ab06f5b0443ef8ddac3aaf076/install.sh | sh -s -- -b /usr/local/bin
- name: Set tag
- name: Set version
run: |
version=$(yq '(.version|split("-"))[0]' rockcraft.yaml)
base=$(yq '(.base|split(":"))[1]' rockcraft.yaml)
echo "tag=${version}-${base}_edge" >> "$GITHUB_ENV"
echo "=${version}" >> "$GITHUB_ENV"
- uses: actions/download-artifact@v3
with:
name: charmed-mysql-rock
- name: Create SBOM
run: syft charmed-mysql_${{env.tag}}_amd64.rock -o spdx-json=charmed-mysql_${{env.tag}}_amd64.rock.spdx.json
run: syft charmed-mysql_${{env.version}}_amd64.rock -o spdx-json=charmed-mysql_${{env.version}}_amd64.rock.spdx.json
- name: Upload SBOM
uses: actions/upload-artifact@v3
with:
path: "charmed-mysql_${{env.tag}}_amd64.rock.spdx.json"
name: charmed-mysql_${{env.tag}}_amd64.rock.spdx.json
path: "charmed-mysql_${{env.version}}_amd64.rock.spdx.json"
name: charmed-mysql_${{env.version}}_amd64.rock.spdx.json

0 comments on commit 528c498

Please sign in to comment.