mirror of
https://github.com/openfaas/faas.git
synced 2025-06-09 00:36:46 +00:00
Update travis to use Go 1.9
Signed-off-by: Alex Ellis (VMware) <alexellis2@gmail.com>
This commit is contained in:
parent
84271240d6
commit
034f2c4d13
@ -1,7 +1,12 @@
|
|||||||
sudo: required
|
sudo: required
|
||||||
|
|
||||||
|
language: go
|
||||||
|
go:
|
||||||
|
- "1.9"
|
||||||
|
|
||||||
services:
|
services:
|
||||||
- docker
|
- docker
|
||||||
|
|
||||||
addons:
|
addons:
|
||||||
apt:
|
apt:
|
||||||
packages:
|
packages:
|
||||||
@ -13,12 +18,14 @@ script:
|
|||||||
- sh build.sh
|
- sh build.sh
|
||||||
# Invoke ci script too
|
# Invoke ci script too
|
||||||
- sh contrib/ci.sh
|
- sh contrib/ci.sh
|
||||||
|
|
||||||
after_success:
|
after_success:
|
||||||
- if [ ! -s "$TRAVIS_TAG" ] ; then
|
- if [ ! -s "$TRAVIS_TAG" ] ; then
|
||||||
docker tag $DOCKER_NS/gateway:latest-dev $DOCKER_NS/gateway:$TRAVIS_TAG;
|
docker tag $DOCKER_NS/gateway:latest-dev $DOCKER_NS/gateway:$TRAVIS_TAG;
|
||||||
docker login -u=$DOCKER_USERNAME -p=$DOCKER_PASSWORD;
|
docker login -u=$DOCKER_USERNAME -p=$DOCKER_PASSWORD;
|
||||||
docker push $DOCKER_NS/gateway:$TRAVIS_TAG;
|
docker push $DOCKER_NS/gateway:$TRAVIS_TAG;
|
||||||
fi
|
fi
|
||||||
|
|
||||||
deploy:
|
deploy:
|
||||||
provider: releases
|
provider: releases
|
||||||
api_key:
|
api_key:
|
||||||
|
@ -3,6 +3,20 @@
|
|||||||
docker swarm init --advertise-addr=127.0.0.1
|
docker swarm init --advertise-addr=127.0.0.1
|
||||||
|
|
||||||
./deploy_stack.sh
|
./deploy_stack.sh
|
||||||
|
docker service update func_gateway --image=functions/gateway:latest-dev
|
||||||
|
|
||||||
|
# Script makes sure OpenFaaS API gateway is ready before running tests
|
||||||
|
|
||||||
|
for i in {1..30};
|
||||||
|
do
|
||||||
|
echo "Checking if 127.0.0.1:8000 is up.. ${i}/30"
|
||||||
|
curl -fs 127.0.0.1:8080/
|
||||||
|
|
||||||
|
if [ $? -eq 0 ]; then
|
||||||
|
break
|
||||||
|
fi
|
||||||
|
sleep 0.5
|
||||||
|
done
|
||||||
|
|
||||||
cd ..
|
cd ..
|
||||||
|
|
||||||
@ -11,14 +25,14 @@ echo $GOPATH
|
|||||||
mkdir -p $GOPATH/src/github.com/openfaas/
|
mkdir -p $GOPATH/src/github.com/openfaas/
|
||||||
cp -r faas $GOPATH/src/github.com/openfaas/
|
cp -r faas $GOPATH/src/github.com/openfaas/
|
||||||
|
|
||||||
git clone https://github.com/openfaas/certify-incubator
|
git clone https://github.com/openfaas/certifier
|
||||||
|
|
||||||
cp -r certify-incubator $GOPATH/src/github.com/openfaas/
|
cp -r certifier $GOPATH/src/github.com/openfaas/
|
||||||
|
|
||||||
cd $GOPATH/src/github.com/openfaas/faas/gateway/tests/integration && \
|
cd $GOPATH/src/github.com/openfaas/faas/gateway/tests/integration && \
|
||||||
go test -v
|
go test -v
|
||||||
|
|
||||||
cd $GOPATH/src/github.com/openfaas/certify-incubator && \
|
cd $GOPATH/src/github.com/openfaas/certifier && \
|
||||||
make test
|
make test
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
|
Loading…
x
Reference in New Issue
Block a user