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

feat(image): Buildkit support for misconfiguration scanning #5989

Closed
knqyf263 opened this issue Jan 24, 2024 Discussed in #5972 · 1 comment · Fixed by #5990
Closed

feat(image): Buildkit support for misconfiguration scanning #5989

knqyf263 opened this issue Jan 24, 2024 Discussed in #5972 · 1 comment · Fixed by #5990
Assignees
Labels
kind/feature Categorizes issue or PR as related to a new feature.

Comments

@knqyf263
Copy link
Collaborator

Description

trivy image --image-config-scanners misconf doesn't work with Buildkit now. Images built by Docker have the /bin/sh -c prefix, while Buildkit doesn't.

$ docker history test
IMAGE          CREATED          CREATED BY                                       SIZE      COMMENT
b1afcbbdcdae   5 seconds ago    ADD foo.txt . # buildkit                         0B        buildkit.dockerfile.v0
<missing>      37 seconds ago   RUN /bin/sh -c ls # buildkit                     0B        buildkit.dockerfile.v0
<missing>      11 months ago    /bin/sh -c #(nop)  CMD ["/bin/sh"]               0B
<missing>      11 months ago    /bin/sh -c #(nop) ADD file:9bd9ea42a9f3bdc76…   7.46MB

Discussed in #5972

@knqyf263 knqyf263 added the kind/feature Categorizes issue or PR as related to a new feature. label Jan 24, 2024
@DmitriyLewen
Copy link
Contributor

DmitriyLewen commented Jan 24, 2024

It might make sense to add support for COPY instructions to buildkit.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/feature Categorizes issue or PR as related to a new feature.
Projects
None yet
2 participants