Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Generate and output sbom in GHA #1121

Merged
merged 2 commits into from
Nov 7, 2024

Conversation

AndreKurait
Copy link
Member

@AndreKurait AndreKurait commented Nov 6, 2024

Description

Use Syft action to generate and output sbom alongside published artifacts.
Added license identifier to created jars.

  • Category: Enhancement
  • Why these changes are required? Users expect software boms with artifacts
  • What is the old behavior before changes and new behavior after changes?

Issues Resolved

Is this a backport? If so, please add backport PR # and/or commits #

Testing

Tested with GHA, see https://github.com/opensearch-project/opensearch-migrations/actions/runs/11713035148?pr=1121

Check List

  • New functionality includes testing
    • All tests pass, including unit test, integration test and doctest
  • New functionality has been documented
  • Commits are signed per the DCO using --signoff

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

Copy link

codecov bot commented Nov 6, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 80.60%. Comparing base (c189ced) to head (acc368a).
Report is 5 commits behind head on main.

Additional details and impacted files
@@             Coverage Diff              @@
##               main    #1121      +/-   ##
============================================
+ Coverage     80.51%   80.60%   +0.09%     
- Complexity     2871     2914      +43     
============================================
  Files           393      393              
  Lines         14554    14630      +76     
  Branches       1000     1007       +7     
============================================
+ Hits          11718    11793      +75     
+ Misses         2229     2228       -1     
- Partials        607      609       +2     
Flag Coverage Δ
gradle-test 78.72% <ø> (+0.12%) ⬆️
python-test 90.33% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

image: migrations/reindex_from_snapshot:latest
artifact-name: opensearch-migrations-reindex-from-snapshot-sbom.spdx.json
- name: Generate SBOM for artifacts
uses: anchore/sbom-action@v0
Copy link
Member

Choose a reason for hiding this comment

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

How did you come to pick this GitHub action, looks like it hasn't been fully released yet?

Copy link
Member Author

Choose a reason for hiding this comment

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

Syft is the industry standard sbom tool that this is running, and is made by it's creators. This was first released in 2021 and has had regular releases since.

If you would prefer, i can manually get the syft binary and run it that way

Copy link
Member Author

Choose a reason for hiding this comment

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

Copy link
Member

Choose a reason for hiding this comment

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

Lets use v0.X.Y to lock to a specific rather than just v0 - dependabot can manage these updates.

Copy link
Member Author

Choose a reason for hiding this comment

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

Updated

Signed-off-by: Andre Kurait <[email protected]>
@AndreKurait AndreKurait merged commit 9345bff into opensearch-project:main Nov 7, 2024
15 checks passed
@AndreKurait AndreKurait deleted the LicenseReport branch November 7, 2024 21:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants