This is an automated email from the ASF dual-hosted git repository. csantanapr pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/incubator-openwhisk-deploy-kube.git
The following commit(s) were added to refs/heads/master by this push: new f9d840d configurable timeout for travis/build.sh (#181) f9d840d is described below commit f9d840d07e5162771e522e9c54ce21aeaab4bf34 Author: David Grove <dgrove-...@users.noreply.github.com> AuthorDate: Mon Apr 16 21:25:12 2018 -0400 configurable timeout for travis/build.sh (#181) Add hook to allow overriding the timeout value used when waiting for a pod to be successfully deployed. I've found when running locally on a fresh minikube VM, it can sometimes take an excessively long time to pull images from dockerhub into the docker registry within the minikube cluster. Setting a high timeout limit avoids needing to run the script multiple times to pull in the needed images. --- tools/travis/build.sh | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/tools/travis/build.sh b/tools/travis/build.sh index e59c8d8..28f1d89 100755 --- a/tools/travis/build.sh +++ b/tools/travis/build.sh @@ -11,7 +11,7 @@ couchdbHealthCheck () { PASSED=false TIMEOUT=0 - until [ $TIMEOUT -eq 60 ]; do + until [ $TIMEOUT -eq $TIMEOUT_STEP_LIMIT ]; do if [ -n "$(kubectl -n openwhisk logs $POD_NAME | grep "successfully setup and configured CouchDB")" ]; then PASSED=true break @@ -39,7 +39,7 @@ deploymentHealthCheck () { PASSED=false TIMEOUT=0 - until $PASSED || [ $TIMEOUT -eq 60 ]; do + until $PASSED || [ $TIMEOUT -eq $TIMEOUT_STEP_LIMIT ]; do KUBE_DEPLOY_STATUS=$(kubectl -n openwhisk get pods -l name="$1" -o wide | grep "$1" | awk '{print $3}') if [ "$KUBE_DEPLOY_STATUS" == "Running" ]; then PASSED=true @@ -70,7 +70,7 @@ statefulsetHealthCheck () { PASSED=false TIMEOUT=0 - until $PASSED || [ $TIMEOUT -eq 60 ]; do + until $PASSED || [ $TIMEOUT -eq $TIMEOUT_STEP_LIMIT ]; do KUBE_DEPLOY_STATUS=$(kubectl -n openwhisk get pods -l name="$1" -o wide | grep "$1"-0 | awk '{print $3}') if [ "$KUBE_DEPLOY_STATUS" == "Running" ]; then PASSED=true @@ -102,7 +102,7 @@ jobHealthCheck () { PASSED=false TIMEOUT=0 - until $PASSED || [ $TIMEOUT -eq 60 ]; do + until $PASSED || [ $TIMEOUT -eq $TIMEOUT_STEP_LIMIT ]; do KUBE_SUCCESSFUL_JOB=$(kubectl -n openwhisk get jobs -o wide | grep "$1" | awk '{print $3}') if [ "$KUBE_SUCCESSFUL_JOB" == "1" ]; then PASSED=true @@ -138,6 +138,9 @@ ROOTDIR="$SCRIPTDIR/../../" # Default to docker container factory if not specified OW_CONTAINER_FACTORY=${OW_CONTAINER_FACTORY:="docker"} +# Default timeout limit to 60 steps +TIMEOUT_STEP_LIMIT=${TIMEOUT_STEP_LIMIT:=60} + cd $ROOTDIR # Label invoker nodes (needed for DockerContainerFactory-based invoker deployment) -- To stop receiving notification emails like this one, please contact csantan...@apache.org.