docker-utils 0.1.35 → 0.1.37
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/share/scripts/block-until-port-open +3 -1
- data/share/scripts/ip +3 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9f700a87c6bd9cb11d71fef1d5f341b43cbd9a0c
|
4
|
+
data.tar.gz: ffbb3763babc45d415b91387ca6a13bc4ca61ce2
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b10845027f5b1651c14b9ac901743fcfa974171d884f756f7339ca8a7cf0b3145f7d95d2a7fff0aeb2a4012bbbcefe77e727688ec5faa474520feefa3863e28b
|
7
|
+
data.tar.gz: 63c364adb4d994043eebd21e95d0c9cc86ddc03fd0e3183d28cdeb0ecdb91ead4ceb5ae41130e0d4107a89bd3c35553209c4e87971c91238d065233575ed43b1
|
@@ -12,6 +12,8 @@ if [ -z "${container_port}" ]; then
|
|
12
12
|
container_port=$(docker-utils exposed -p "${container_name}" | head -n 1)
|
13
13
|
fi
|
14
14
|
|
15
|
+
sleep_interval='0.1'
|
15
16
|
until docker-utils "port-open?" "${container_name}" "${container_port}"; do
|
16
|
-
sleep
|
17
|
+
sleep "${sleep_interval}"
|
18
|
+
sleep_interval=$(echo "((${sleep_interval} * 2) % 10) + 0.1" | bc)
|
17
19
|
done
|
data/share/scripts/ip
CHANGED
@@ -9,13 +9,15 @@ container_name="$1"; shift
|
|
9
9
|
|
10
10
|
container_ip_addr=""
|
11
11
|
|
12
|
+
sleep_interval='0.1'
|
12
13
|
if [ "${mode}" = "wait" ]; then
|
13
14
|
while :; do
|
14
15
|
container_ip_addr=$(command docker inspect --format '{{.NetworkSettings.IPAddress}}' "${container_name}" 2>/dev/null)
|
15
16
|
if [ -n "${container_ip_addr}" ]; then
|
16
17
|
break
|
17
18
|
fi
|
18
|
-
sleep
|
19
|
+
sleep "${sleep_interval}"
|
20
|
+
sleep_interval=$(echo "((${sleep_interval} * 2) % 10) + 0.1" | bc)
|
19
21
|
done
|
20
22
|
else
|
21
23
|
container_ip_addr=$(command docker inspect --format '{{.NetworkSettings.IPAddress}}' "${container_name}" 2>/dev/null)
|