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

support collection of image labels #227

Merged
merged 1 commit into from
Nov 8, 2023
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
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ require (
oras.land/oras-go/v2 v2.3.0
)

replace github.com/anchore/syft => github.com/noqcks/syft v0.0.0-20231012144435-aa2262d32557
replace github.com/anchore/syft => github.com/noqcks/syft v0.0.0-20231107190905-9cd3f1bd08e2

require (
cloud.google.com/go v0.110.2 // indirect
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -814,8 +814,8 @@ github.com/muesli/reflow v0.3.0/go.mod h1:pbwTDkVPibjO2kyvBQRBxTWEEGDGq0FlB1BIKt
github.com/muesli/termenv v0.15.2 h1:GohcuySI0QmI3wN8Ok9PtKGkgkFIk7y6Vpb5PvrY+Wo=
github.com/muesli/termenv v0.15.2/go.mod h1:Epx+iuz8sNs7mNKhxzH4fWXGNpZwUaJKRS1noLXviQ8=
github.com/mwitkow/go-conntrack v0.0.0-20161129095857-cc309e4a2223/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U=
github.com/noqcks/syft v0.0.0-20231012144435-aa2262d32557 h1:tIxmEmvbxchiGw/llyU7XJhtOZl7LdCTX0nIKO32N4I=
github.com/noqcks/syft v0.0.0-20231012144435-aa2262d32557/go.mod h1:JTwDULqhUlXmeOJXhbesxhY6zG2due9cefe0E01pneE=
github.com/noqcks/syft v0.0.0-20231107190905-9cd3f1bd08e2 h1:Fb07E7QFWDLDO0UBa1oTtz+lkn/uSQd/wtCZiath/Ss=
github.com/noqcks/syft v0.0.0-20231107190905-9cd3f1bd08e2/go.mod h1:JTwDULqhUlXmeOJXhbesxhY6zG2due9cefe0E01pneE=
github.com/notaryproject/notation v1.0.0 h1:CJ17obUMRJOljApN8NCgYNmxfJQ878UrN0VbKACvDW0=
github.com/notaryproject/notation v1.0.0/go.mod h1:BrPDyD390EOKkzLDS/3tEbg79wLIkNc0vCLfKHTd0Hw=
github.com/notaryproject/notation-core-go v1.0.0 h1:FgOAihtFW4XU9JYyTzItg1xW3OaN4eCasw5Bp00Ydu4=
Expand Down
3 changes: 3 additions & 0 deletions internal/xeolio/source.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,15 @@ type ImageSource struct {
Type string
ImageName string
ImageDigest string
ImageLabels map[string]string
}

func NewImageSource(imageSource source.StereoscopeImageSourceMetadata) *ImageSource {
return &ImageSource{
Type: "ImageScheme",
ImageName: imageSource.UserInput,
ImageDigest: imageSource.ManifestDigest,
ImageLabels: imageSource.Labels,
}
}

Expand All @@ -48,6 +50,7 @@ func (s *ImageSource) Serialize() map[string]interface{} {
"Type": s.Type,
"ImageName": s.ImageName,
"ImageDigest": s.ImageDigest,
"ImageLabels": s.ImageLabels,
}
}

Expand Down