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

Generating SBOM for containers #3929

Open
2 tasks done
buger opened this issue Apr 11, 2023 · 2 comments
Open
2 tasks done

Generating SBOM for containers #3929

buger opened this issue Apr 11, 2023 · 2 comments
Assignees
Labels
enhancement New feature or request
Milestone

Comments

@buger
Copy link

buger commented Apr 11, 2023

Is your feature request related to a problem? Please describe.

I see that for some reason SBOM feature does not work with generated containers.
Is there any reasons behind it? Anything community can help to make it work, can you give some direction on it?

Describe the solution you'd like

Be able generate SBOM for container artifacts

Describe alternatives you've considered

Having a separate job, running after goreleaser, which builds container SBOM

Search

  • I did search for other open and closed issues before opening this.

Code of Conduct

  • I agree to follow this project's Code of Conduct

Additional context

No response

@buger buger added enhancement New feature or request triage Issue pending triage by one of the maintainers labels Apr 11, 2023
@caarlos0
Copy link
Member

I think it merely wasn't implemented...

If anyone wants to take a swing at it, I can give pointers here and/or discord...

The way I would go about it, probably, is to create a DockerPipe in the sbom package and implement the required methods, reusing the same code where it makes sense...

That should allow to run that particular pipe (sbom.DockerPipe) in the publish phase (instead of the build phase as the regular sbom.Pipe runs), which if I recall is how syft et al works (they publish the image with the sbom attached afaik - if that's incorrect we might do something different though).

FWIW: it works for kos.

@caarlos0 caarlos0 removed the triage Issue pending triage by one of the maintainers label Apr 11, 2023
@caarlos0
Copy link
Member

Using buildx, you can also add --attest to your dockers build_flag_templates: https://docs.docker.com/engine/sbom/?cmdf=docker+sbom

@caarlos0 caarlos0 added this to the v1.19.0 milestone May 8, 2023
@caarlos0 caarlos0 modified the milestones: v1.19.0, v1.20.0 Jun 15, 2023
@caarlos0 caarlos0 modified the milestones: v1.20.0, v1.21.0 Aug 12, 2023
@caarlos0 caarlos0 modified the milestones: v1.21.0, v1.22.0 Sep 23, 2023
@caarlos0 caarlos0 modified the milestones: v1.22.0, v1.23.0 Nov 7, 2023
@caarlos0 caarlos0 modified the milestones: v1.23.0, v1.24.0 Dec 29, 2023
@caarlos0 caarlos0 modified the milestones: v1.24.0, v1.25.0 Feb 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants