Description
When I use the docker
image as a build step in Google Cloud Build to perform buildx builds, I get the following warning:
WARNING: current commit information was not captured by the build: git was not found in the system: exec: "git": executable file not found in $PATH
I presume this has to do with provenance being enabled by default per https://docs.docker.com/build/attestations/slsa-provenance/#mode
I would like to be able to use the docker
image to run docker buildx ...
and have the provenance information captured as designed by the new default. I know about the option to suppress the warning by using BUILDX_NO_DEFAULT_ATTESTATIONS=1
to disable the feature entirely, but I would prefer to get it working instead.
As an end user I have no preference between what I presume are the two possible solutions:
- Modify the provenance feature to extract the required information without running
git
as a child process. - Add
git
to thedocker
image.
(I'm opening this issue here because I presume the second option is much more reasonable to implement.)