Fix Travis IPv6 and add k8s integration testing to CI (#194)

Updating travis yaml file to:
* Force IPv6 to work in their VM environment
* Enable docker (requires VM environment and sudo)
* Run kubernetes integration tests in Travis
This commit is contained in:
Michael Richmond
2016-07-27 10:01:24 -07:00
committed by GitHub
parent 4a3b57d81b
commit 8dec292668
8 changed files with 54 additions and 13 deletions

View File

@@ -7,7 +7,6 @@ K8S_VERSION="v1.2.4"
ARCH="amd64"
export K8S_VERSION
export ARCH

View File

@@ -1,7 +1,7 @@
#!/bin/bash
PWD=`pwd`
BASEDIR=`realpath $(dirname ${0})`
BASEDIR=`readlink -e $(dirname ${0})`
cd ${BASEDIR}
if [ ! -e kubectl ]; then

View File

@@ -2,6 +2,11 @@
# Running skydns based on instructions at: https://testdatamanagement.wordpress.com/2015/09/01/running-kubernetes-in-docker-with-dns-on-a-single-node/
PWD=`pwd`
BASEDIR=`readlink -e $(dirname ${0})`
cd ${BASEDIR}
KUBECTL='./kubectl'
#RUN_SKYDNS="yes"
@@ -15,7 +20,7 @@ wait_until_k8s_ready() {
if [ "${?}" = "0" ]; then
break
else
echo "sleeping for 5 seconds"
echo "sleeping for 5 seconds (waiting for kubernetes to start)"
sleep 5
fi
done
@@ -37,3 +42,5 @@ if [ "${RUN_SKYDNS}" = "yes" ]; then
else
true
fi
cd ${PWD}

View File

@@ -1,16 +1,21 @@
#!/bin/bash
PWD=`pwd`
BASEDIR=`readlink -e $(dirname ${0})`
cd ${BASEDIR}
KUBECTL='./kubectl'
wait_until_k8s_ready() {
# Wait until kubernetes is up and fully responsive
while :
do
${KUBECTL} get nodes 2>/dev/null | grep -q '127.0.0.1'
${KUBECTL} get nodes 2>/dev/null | grep -q '127.0.0.1'
if [ "${?}" = "0" ]; then
break
else
echo "sleeping for 5 seconds"
echo "sleeping for 5 seconds (waiting for kubernetes to start)"
sleep 5
fi
done
@@ -78,3 +83,5 @@ run_and_expose_service webserver test nginx 80
echo ""
echo "Services exposed:"
${KUBECTL} get services --all-namespaces
cd ${PWD}