aboutsummaryrefslogtreecommitdiffstats
path: root/docker/wait_for_net.sh
diff options
context:
space:
mode:
authorStephane Desneux <stephane.desneux@iot.bzh>2016-11-30 23:53:02 +0100
committerStephane Desneux <stephane.desneux@iot.bzh>2016-11-30 23:53:02 +0100
commit19828c52e5b50de79739e2c206382be74e596847 (patch)
tree1a29e87054648ae49ebd36aaf68737e8dcef0be7 /docker/wait_for_net.sh
parent5e50ec8d65705b41140d06ec13611f0b3108f7b9 (diff)
group build files into folder INSTALL
Change-Id: Ib76d53f9ff0aed21f12ebd7aac66c1e877bea4a5 Signed-off-by: Stephane Desneux <stephane.desneux@iot.bzh>
Diffstat (limited to 'docker/wait_for_net.sh')
-rwxr-xr-xdocker/wait_for_net.sh19
1 files changed, 0 insertions, 19 deletions
diff --git a/docker/wait_for_net.sh b/docker/wait_for_net.sh
deleted file mode 100755
index 354e76a..0000000
--- a/docker/wait_for_net.sh
+++ /dev/null
@@ -1,19 +0,0 @@
-#!/bin/bash
-
-### this script is used as entrypoint of the docker container to wait for network to be up ###
-
-IFACE="veth0 eth0"
-
-function wait_net() {
- for i in $IFACE; do
- [[ "$(cat /sys/class/net/$i/operstate 2>/dev/null)" == "up" ]] && return 1
- done
- return 0
-}
-
-while wait_net; do
- sleep 1
-done
-
-[[ $# > 0 ]] && exec "$@"
-exec /bin/bash -l