chalk build fails due to invalid --metadata-file flag.
Description
In older docker versions, as docker build is not an alias to docker buildx build, --metadata-file flag is not supported. It only works when explicitly using docker buildx build in which case 0.6.0 is required which added that flag. Otherwise docker version needs to be >=22 which aliased build to buildx build as well as have supported buildx version.
No easy way of testing it in CI but tested locally various combination of versions.
Testing
Was running something like:
➜ echo '
FROM docker:22.06-rc
COPY --from=docker/buildx-bin:0.6.0 /buildx /usr/lib/docker/cli-plugins/docker-buildx
COPY --from=docker/buildx-bin:0.6.0 /buildx /usr/local/libexec/docker/cli-plugins/docker-buildx
' | docker build -f - . -t dockerbuildx
and docker run -it --rm dockerbuildx docker --version
and docker run -it --rm dockerbuildx buildx version
and docker run -it --rm dockerbuildx build --help
and docker run -it --rm dockerbuildx buildx build --help
CHANGELOG.md
if necessaryIssue
chalk build fails due to invalid
--metadata-file
flag.Description
In older docker versions, as
docker build
is not an alias todocker buildx build
,--metadata-file
flag is not supported. It only works when explicitly usingdocker buildx build
in which case 0.6.0 is required which added that flag. Otherwise docker version needs to be >=22 which aliasedbuild
tobuildx build
as well as have supported buildx version.No easy way of testing it in CI but tested locally various combination of versions.
Testing
Was running something like: