From: Jan Kiszka <[email protected]>

Upcoming kas will support interactive mode, deriving it from the calling
context. Make sure that one is consistent with the calling context of
build-images.sh.

Signed-off-by: Jan Kiszka <[email protected]>
---
 build-images.sh | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/build-images.sh b/build-images.sh
index 87bfc28..6900221 100755
--- a/build-images.sh
+++ b/build-images.sh
@@ -98,11 +98,16 @@ if [ -z "${KAS_TARGET}" ]; then
        done
 fi
 
+if [ -t 1 ]; then
+       INTERACTIVE="-t -i"
+fi
+
 mkdir -p out
 docker run -v $(pwd):/jailhouse-images:ro -v $(pwd)/out:/out:rw \
           -e USER_ID=$(id -u) -e SHELL=${SHELL} \
           -e KAS_TARGET="${KAS_TARGET}" -e KAS_TASK="${KAS_TASK}" \
-          --rm -t -i --cap-add=SYS_ADMIN --cap-add=MKNOD --privileged \
+          --rm ${INTERACTIVE} \
+          --cap-add=SYS_ADMIN --cap-add=MKNOD --privileged \
           --device $(/sbin/losetup -f) \
           -e http_proxy=$http_proxy -e https_proxy=$https_proxy \
           -e no_proxy=$no_proxy ${DOCKER_ARGS} \
-- 
2.16.4

-- 
You received this message because you are subscribed to the Google Groups 
"Jailhouse" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to