wrapper/docker: don't suppress docker build stdout when verbose enabled

This commit is contained in:
InsanePrawn 2023-01-02 02:41:59 +01:00
parent d3cc5e9483
commit 1a695adff4

View file

@ -38,7 +38,12 @@ class DockerWrapper(Wrapper):
tag,
] + (['-q'] if not config.runtime.verbose else [])
logging.debug('Running docker cmd: ' + ' '.join(cmd))
result = subprocess.run(cmd, cwd=script_path, capture_output=True)
result = subprocess.run(
cmd,
cwd=script_path,
stdout=(sys.stdout if config.runtime.verbose else subprocess.PIPE),
stderr=(sys.stderr if config.runtime.verbose else subprocess.PIPE),
)
if result.returncode != 0:
logging.fatal('Failed to build docker image:\n' + result.stderr.decode())
exit(1)