Skip to content

Commit

Permalink
ci: Optimize Travis waiting for ES
Browse files Browse the repository at this point in the history
  • Loading branch information
olivere committed Aug 18, 2018
1 parent ba73507 commit ada4bb4
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,15 @@ addons:
services:
- docker
before_install:
- if [[ "$TRAVIS_OS_NAME" == "linux" && ! $(which nc) ]] ; then sudo apt-get install -y netcat ; fi
- sudo sysctl -w vm.max_map_count=262144
# - docker run -d --rm -p 9200:9200 -e "http.host=0.0.0.0" -e "transport.host=127.0.0.1" -e "bootstrap.memory_lock=true" -e "ES_JAVA_OPTS=-Xms1g -Xmx1g" docker.elastic.co/elasticsearch/elasticsearch:6.3.2 elasticsearch -Enetwork.host=_local_,_site_ -Enetwork.publish_host=_local_
- docker-compose pull
- docker-compose up -d
- sleep 15
- go get -u github.com/fortytw2/leaktest
- go get . ./config ./aws ./trace/...
- while ! nc -z localhost 9200; do sleep 1; done
- while ! nc -z localhost 9210; do sleep 1; done
install: true # ignore the go get -t -v ./...
script:
- go test -race -v . ./config ./aws ./trace/...

0 comments on commit ada4bb4

Please sign in to comment.