docs icon indicating copy to clipboard operation
docs copied to clipboard

Documentation regarding warning on unused build args is no longer accurate with BuildKit

Open Ga22be opened this issue 11 months ago • 0 comments

Is this a docs issue?

  • [X] My issue is about the documentation content or website

Type of issue

Information is incorrect

Description

The documentation for Dockerfiles and ARGs state:

If you specify a build argument that wasn't defined in the Dockerfile, the build outputs a warning.

"[Warning] One or more build-args [foo] were not consumed."

This didn't work for me and I was pulling my hair until I found this: https://github.com/moby/buildkit/issues/2128

It does however work if I disable BuildKit using: DOCKER_BUILDKIT=0

Location

https://docs.docker.com/reference/dockerfile/

Suggestion

While the simple solution would be to remove the information all together I would like it to temporarily note that it works for the old builder. The error was useful and if it is removed now I fear that it will not be added again if fixed in BuildKit.

Ga22be avatar Mar 05 '24 11:03 Ga22be