2

When I run a build using docker-compose build --progress plain, it shows more useful information during the build than the default BuildKit output.

Is there a way to embed the plain progress option into the docker-compose.yml file itself so I can just call docker-compose build and still get the better output?

I tried adding these build args, but none of them seemed to work:

build:
    args:
        #progress: plain  
        #- progress=plain  
        #- progress plain  
        #BUILDKIT_PROGRESS: plain  
        #- BUILDKIT_PROGRESS=plain  

1 Answers1

0

Even though it seems like it ought to be possible looking at the current implementation of docker-compose, notably the _CLIBuilder which is invoked over the services dict's build method.

However, no such similarly-named key exists in the configuration schema.

So it appears that you can't, at least not yet.

Incidentally, from the above, I'd expect to eventually find it here

services:
    build:
        progress: plain

rather than the args: child key.

msanford
  • 10,127
  • 8
  • 56
  • 83
  • 1
    Well that's disappointing. Your sample code is exactly how I want it to work! – Allan Jackson May 14 '21 at 17:44
  • @AllanJackson Indeed. The fact that the underlying methods _seem to_ support it suggests that it's a feature they're allowing for in the future. BuildKit is still _fairly_ newish... (To close the question, you can mark this as accepted, and move it if someone else provides a better answer.) – msanford May 14 '21 at 18:18