@@ -164,11 +164,12 @@ def __init__(self, docker_bin=None):
164
164
class DockerCompose (Command ):
165
165
166
166
def __init__ (self , config_path , dotenv_path = None , compose_bin = None ,
167
- params = None ):
167
+ params = None , debug = False ):
168
168
compose_bin = default_bin (compose_bin , 'docker-compose' )
169
169
self .config = ComposeConfig (config_path , dotenv_path , compose_bin ,
170
170
params )
171
171
self .bin = compose_bin
172
+ self .debug = debug
172
173
self .pull_memory = set ()
173
174
174
175
def clear_pull_memory (self ):
@@ -296,6 +297,8 @@ def _build(service, use_cache):
296
297
self ._execute_docker ("buildx" , "build" , * args )
297
298
elif using_docker :
298
299
# better for caching
300
+ if self .debug :
301
+ args .append ("--progress=plain" )
299
302
for k , v in service ['build' ].get ('args' , {}).items ():
300
303
args .extend (['--build-arg' , '{}={}' .format (k , v )])
301
304
for img in cache_from :
@@ -307,6 +310,8 @@ def _build(service, use_cache):
307
310
])
308
311
self ._execute_docker ("build" , * args )
309
312
else :
313
+ if self .debug :
314
+ args .append ("--progress=plain" )
310
315
self ._execute_compose ("build" , * args , service ['name' ])
311
316
312
317
service = self .config .get (service_name )
0 commit comments