From: Thomas Huth <thuth@redhat.com>
To: Peter Maydell <peter.maydell@linaro.org>
Cc: qemu-devel@nongnu.org, "Daniel P. Berrangé" <berrange@redhat.com>
Subject: [PULL 09/10] tests/docker: allow display of docker output
Date: Mon, 2 Mar 2026 13:34:12 +0100 [thread overview]
Message-ID: <20260302123413.274700-10-thuth@redhat.com> (raw)
In-Reply-To: <20260302123413.274700-1-thuth@redhat.com>
From: Daniel P. Berrangé <berrange@redhat.com>
The --quiet command is used with docker unless V=1 is passed to make,
and as a result stdout from docker is never visible by default, making
it hard to diagnose failures building / running containers.
Meanwhile passing V=1 is undesirable as that makes the entire build
system verbose.
Introduce a $(DOCKER_V) make variable which is initialized from $(V)
It is thus possible to display docker output without also enabling
make verbose output.
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Message-ID: <20260210163556.713841-4-berrange@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
---
tests/docker/Makefile.include | 20 +++++++++++++-------
1 file changed, 13 insertions(+), 7 deletions(-)
diff --git a/tests/docker/Makefile.include b/tests/docker/Makefile.include
index 7d4582b6a8d..df14538c0f5 100644
--- a/tests/docker/Makefile.include
+++ b/tests/docker/Makefile.include
@@ -23,6 +23,8 @@ RUNC ?= $(shell $(DOCKER_SCRIPT) probe)
CUR_TIME := $(shell date +%Y-%m-%d-%H.%M.%S.$$$$)
DOCKER_SRC_COPY := $(BUILD_DIR)/docker-src.$(CUR_TIME)
+DOCKER_V ?= $(V)
+
.DELETE_ON_ERROR: $(DOCKER_SRC_COPY)
$(DOCKER_SRC_COPY):
@mkdir $@
@@ -40,14 +42,14 @@ docker-qemu-src: $(DOCKER_SRC_COPY)
docker-image-%: $(DOCKER_FILES_DIR)/%.docker
$(call quiet-command, \
DOCKER_BUILDKIT=1 $(RUNC) build \
- $(if $V,,--quiet) \
+ $(if $(DOCKER_V),,--quiet) \
$(if $(NOCACHE),--no-cache, \
$(if $(DOCKER_REGISTRY),--cache-from $(DOCKER_REGISTRY)/qemu/$*)) \
--build-arg BUILDKIT_INLINE_CACHE=1 \
$(if $(NOUSER),, \
--build-arg USER=$(USER) \
--build-arg UID=$(UID)) \
- -t qemu/$* - < $< $(if $V,,> /dev/null),\
+ -t qemu/$* - < $< $(if $(DOCKER_V),,> /dev/null),\
"BUILD", $*)
# General rule for inspecting registry images.
@@ -73,7 +75,7 @@ docker-binfmt-image-debian-%: $(DOCKER_FILES_DIR)/debian-bootstrap.docker
DEB_TYPE=$(DEB_TYPE) \
$(if $(DEB_URL),DEB_URL=$(DEB_URL),) \
$(DOCKER_SCRIPT) build -t qemu/debian-$* -f $< \
- $(if $V,,--quiet) $(if $(NOCACHE),--no-cache) \
+ $(if $(DOCKER_V),,--quiet) $(if $(NOCACHE),--no-cache) \
$(if $(NOUSER),,--add-current-user) \
$(if $(EXTRA_FILES),--extra-files $(EXTRA_FILES)) \
$(if $(EXECUTABLE),--include-executable=$(EXECUTABLE)), \
@@ -105,16 +107,17 @@ debian-toolchain-run = \
$(if $(NOCACHE)$(NOFETCH), \
$(call quiet-command, \
$(DOCKER_SCRIPT) build -t qemu/$1 -f $< \
- $(if $V,,--quiet) $(if $(NOCACHE),--no-cache) \
+ $(if $(DOCKER_V),,--quiet) \
+ $(if $(NOCACHE),--no-cache) \
--registry $(DOCKER_REGISTRY) --extra-files \
$(DOCKER_FILES_DIR)/$1.d/build-toolchain.sh, \
"BUILD", $1), \
$(call quiet-command, \
- $(DOCKER_SCRIPT) fetch $(if $V,,--quiet) \
+ $(DOCKER_SCRIPT) fetch $(if $(DOCKER_V),,--quiet) \
qemu/$1 $(DOCKER_REGISTRY), \
"FETCH", $1) \
$(call quiet-command, \
- $(DOCKER_SCRIPT) update $(if $V,,--quiet) \
+ $(DOCKER_SCRIPT) update $(if $(DOCKER_V),,--quiet) \
qemu/$1 \
$(if $(NOUSER),,--add-current-user) \
"PREPARE", $1))
@@ -231,7 +234,10 @@ docker-run: docker-qemu-src
-e TARGET_LIST=$(subst $(SPACE),$(COMMA),$(TARGET_LIST)) \
-e EXTRA_CONFIGURE_OPTS="$(EXTRA_CONFIGURE_OPTS)" \
-e TEST_COMMAND="$(TEST_COMMAND)" \
- -e V=$V -e J=$J -e DEBUG=$(DEBUG) \
+ -e V=$V \
+ -e DOCKER_V=$(DOCKER_V) \
+ -e J=$J \
+ -e DEBUG=$(DEBUG) \
-e SHOW_ENV=$(SHOW_ENV) \
$(if $(NOUSER),, \
-v $(DOCKER_QEMU_CACHE_DIR):$(DOCKER_QEMU_CACHE_DIR) \
--
2.53.0
next prev parent reply other threads:[~2026-03-02 12:36 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-02 12:34 [PULL 00/10] microblazeel removal, improved docker detection, etc Thomas Huth
2026-03-02 12:34 ` [PULL 01/10] s390x/pci: prevent null pointer dereference during zpci hot unplug Thomas Huth
2026-03-02 12:34 ` [PULL 02/10] tests/functional: Make sure test case .py files are executable Thomas Huth
2026-03-02 12:34 ` [PULL 03/10] tests/functional: Remove the microblazeel test Thomas Huth
2026-03-02 12:34 ` [PULL 04/10] tests/qtest: Remove the microblazeel target from the qtests Thomas Huth
2026-03-02 12:34 ` [PULL 05/10] gitlab-ci: Remove the microblazeel target from the CI jobs Thomas Huth
2026-03-02 12:34 ` [PULL 06/10] Remove the qemu-system-microblazeel target from the build Thomas Huth
2026-03-02 12:34 ` [PULL 07/10] tests/docker: improve handling of docker probes Thomas Huth
2026-03-02 12:34 ` [PULL 08/10] tests/docker: add support for podman remote access Thomas Huth
2026-03-02 12:34 ` Thomas Huth [this message]
2026-03-02 12:34 ` [PULL 10/10] gitlab: ensure docker output is always displayed in CI Thomas Huth
2026-03-03 9:43 ` [PULL 00/10] microblazeel removal, improved docker detection, etc Peter Maydell
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260302123413.274700-10-thuth@redhat.com \
--to=thuth@redhat.com \
--cc=berrange@redhat.com \
--cc=peter.maydell@linaro.org \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.