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

Added namespace and detection of binary for SBOM scanners #400

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

LaurentGoderre
Copy link

@LaurentGoderre LaurentGoderre commented Jul 15, 2024

Using Syft, the binary has some sub-optimal metadata. It reports 2 main module (package-manager and command-line-argument) and the version of the binary is not detected. THis PR changes the build to inject the version at build time using git to generate the tag id.

After this change, this is how Syft reports the binary

NAME                                            VERSION            TYPE        
github.com/hashicorp/go-version                 v1.7.0             go-module    
github.com/liquibase/liquibase-package-manager  v0.2.7-2-g3363b9c  go-module    
github.com/spf13/cobra                          v1.8.1             go-module    
github.com/spf13/pflag                          v1.0.5             go-module    
stdlib                                          go1.22.5           go-module

P.S. VS Code did some autolinting as well.

@LaurentGoderre
Copy link
Author

Running this results in

liquibase@85b5f93b5da1:/liquibase$ lpm -v
lpm (Liquibase Package Manager) version v0.2.7-2-g0d564a8
liquibase@85b5f93b5da1:/liquibase$ 

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.

1 participant