]> git.puffer.fish Git - mirror/frr.git/commitdiff
topotests: Only set -t when input is a terminal 3396/head
authorChristian Franke <chris@opensourcerouting.org>
Thu, 29 Nov 2018 15:05:44 +0000 (16:05 +0100)
committerChristian Franke <chris@opensourcerouting.org>
Thu, 29 Nov 2018 15:51:27 +0000 (16:51 +0100)
Signed-off-by: Christian Franke <chris@opensourcerouting.org>
tests/topotests/docker/frr-topotests.sh

index 9a157c49a81678c4593eea4c36af5cce04f0f538..673354f5dabb162ed436e32f7c9aa9aac6675693 100755 (executable)
@@ -130,7 +130,7 @@ if [ -z "$TOPOTEST_BUILDCACHE" ]; then
                || docker volume create "${TOPOTEST_BUILDCACHE}"
 fi
 
-set -- --rm -ti \
+set -- --rm -i \
        -v "$TOPOTEST_LOGS:/tmp" \
        -v "$TOPOTEST_FRR:/root/host-frr:ro" \
        -v "$TOPOTEST_FRR/tests/topotests:/root/topotests:ro" \
@@ -143,4 +143,8 @@ set -- --rm -ti \
        $TOPOTEST_OPTIONS \
        frrouting/frr:topotests-latest "$@"
 
+if [ -t 0 ]; then
+       set -- -t "$@"
+fi
+
 exec docker run "$@"