1
0

Extend timeout for restart test

This commit is contained in:
Nicolas Duchon 2019-01-08 16:46:04 +01:00
parent c821d809f6
commit 52b7a51ca2
No known key found for this signature in database
GPG Key ID: EA3151C66A4D79E7

@ -51,15 +51,15 @@ for domain in "${domains[@]}"; do
# Check if container restarted # Check if container restarted
timeout="$(date +%s)" timeout="$(date +%s)"
timeout="$((timeout + 60))" timeout="$((timeout + 120))"
until grep "$domain" "${TRAVIS_BUILD_DIR}"/test/tests/container_restart/docker_event_out.txt; do until grep "$domain" "${TRAVIS_BUILD_DIR}"/test/tests/container_restart/docker_event_out.txt; do
if [[ "$(date +%s)" -gt "$timeout" ]]; then if [[ "$(date +%s)" -gt "$timeout" ]]; then
echo "Container $domain didn't restart in under one minute." echo "Container $domain didn't restart in under two minute."
break break
fi fi
sleep 0.1 sleep 0.1
done done
# Stop the Nginx container silently. # Stop the Nginx container silently.
docker stop "$domain" > /dev/null docker stop "$domain" > /dev/null
done done