From: Fam Zheng <famz@redhat.com>
To: qemu-devel@nongnu.org
Cc: pbonzini@redhat.com, "Fam Zheng" <famz@redhat.com>,
"Philippe Mathieu-Daudé" <f4bug@amsat.org>,
"Alex Bennée" <alex.bennee@linaro.org>
Subject: [Qemu-devel] [PATCH] docker: Don't mount ccache db if NOUSER=1
Date: Mon, 25 Sep 2017 15:54:58 +0800 [thread overview]
Message-ID: <20170925075458.18047-1-famz@redhat.com> (raw)
With NOUSER=1 the container runs code as root, which may create
privileged files that will not be be accssible next time. Skip ccache
dir mount in this case.
Signed-off-by: Fam Zheng <famz@redhat.com>
---
tests/docker/Makefile.include | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/tests/docker/Makefile.include b/tests/docker/Makefile.include
index 0e4f159619..6f9ea196a7 100644
--- a/tests/docker/Makefile.include
+++ b/tests/docker/Makefile.include
@@ -143,9 +143,11 @@ docker-run: docker-qemu-src
-e EXTRA_CONFIGURE_OPTS="$(EXTRA_CONFIGURE_OPTS)" \
-e V=$V -e J=$J -e DEBUG=$(DEBUG) \
-e SHOW_ENV=$(SHOW_ENV) \
- -e CCACHE_DIR=/var/tmp/ccache \
+ $(if $(NOUSER),, \
+ -e CCACHE_DIR=/var/tmp/ccache \
+ -v $(DOCKER_CCACHE_DIR):/var/tmp/ccache:z \
+ ) \
-v $$(readlink -e $(DOCKER_SRC_COPY)):/var/tmp/qemu:z$(COMMA)ro \
- -v $(DOCKER_CCACHE_DIR):/var/tmp/ccache:z \
$(IMAGE) \
/var/tmp/qemu/run \
$(TEST), " RUN $(TEST) in ${IMAGE}")
--
2.13.5
next reply other threads:[~2017-09-25 7:55 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-09-25 7:54 Fam Zheng [this message]
2017-09-28 2:07 ` [Qemu-devel] [PATCH] docker: Don't mount ccache db if NOUSER=1 Philippe Mathieu-Daudé
2017-09-28 7:09 ` Fam Zheng
2017-09-28 14:47 ` Alex Bennée
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=20170925075458.18047-1-famz@redhat.com \
--to=famz@redhat.com \
--cc=alex.bennee@linaro.org \
--cc=f4bug@amsat.org \
--cc=pbonzini@redhat.com \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).