general: branches: ignore: - gh\-pages - /pull\/.*/ machine: services: - docker environment: GOPATH: /home/ubuntu:$GOPATH SRCDIR: /home/ubuntu/src/github.com/weaveworks/weave PATH: $PATH:$HOME/.local/bin:$HOME/google-cloud-sdk/bin/ CLOUDSDK_CORE_DISABLE_PROMPTS: 1 WEAVE_BUILD: $HOME/docker/weave-build.tar dependencies: cache_directories: - "~/docker" override: - if [[ -e "$WEAVE_BUILD" ]]; then docker load -i $WEAVE_BUILD; else docker build -t weaveworks/weave-build build; mkdir -p $(dirname "$WEAVE_BUILD"); docker save weaveworks/weave-build >$WEAVE_BUILD; fi post: - sudo apt-get install bc - pip install requests - curl https://sdk.cloud.google.com | bash - bin/setup-circleci-secrets "$SECRET_PASSWORD" - mkdir -p $(dirname $SRCDIR) - cp -r $(pwd)/ $SRCDIR test: override: - docker run -v /var/run/docker.sock:/run/docker.sock -v /home/ubuntu:/home/go -e COVERDIR=test/coverage -e SLOW=true -e CIRCLECI -e CIRCLE_BUILD_NUM -e CIRCLE_NODE_TOTAL -e CIRCLE_NODE_INDEX weaveworks/weave-build tests: parallel: true - docker run -v /var/run/docker.sock:/run/docker.sock -v /home/ubuntu:/home/go -e COVERAGE=true weaveworks/weave-build: parallel: true - cd $SRCDIR/test; ./gce.sh setup: parallel: true - cd $SRCDIR/test; eval $(./gce.sh hosts); ./setup.sh: parallel: true - cd $SRCDIR/test; eval $(./gce.sh hosts); export COVERAGE=true; ./run_all.sh: parallel: true timeout: 300 post: - cd $SRCDIR/test; ./gce.sh destroy: parallel: true teardown: pre: - test "$CIRCLE_NODE_INDEX" != "0" || (cd $SRCDIR/test; ./gen_coverage_reports.sh): parallel: true - test "$CIRCLE_NODE_INDEX" != "0" || (go get github.com/mattn/goveralls && goveralls -repotoken $COVERALLS_REPO_TOKEN -coverprofile=$SRCDIR/test/profile.cov -service=circleci || true): parallel: true - test "$CIRCLE_NODE_INDEX" != "0" || (cd $SRCDIR/test; cp coverage.* $CIRCLE_ARTIFACTS): parallel: true