surrealpatch/circle.yml
2017-03-04 11:01:14 +00:00

54 lines
1.5 KiB
YAML

# -----------------------------------
machine:
timezone:
UTC
services:
- docker
# -----------------------------------
checkout:
post:
# git tags are used to generate build info which is baked into the
# binary, but unfortunately it is not possible to fetch all tags
# without also unshallowing the checkout, so we must do both.
- git fetch --unshallow --tags
# GOPATH is cached, so we need to clean out the version from the previous
# run or the subsequent `mv` will fail.
- rm -rf "${GOPATH%%:*}/src/github.com/abcum/surreal"
- mkdir -p "${GOPATH%%:*}/src/github.com/abcum/"
- mv ~/surreal "${GOPATH%%:*}/src/github.com/abcum/"
- ln -s "${GOPATH%%:*}/src/github.com/abcum/surreal" ~/surreal
# -----------------------------------
dependencies:
override:
- docker info
- docker login -e $DOCKER_EMAIL -u $DOCKER_USER -p $DOCKER_PASS
- go get -u github.com/Masterminds/glide
- go get -u github.com/mattn/goveralls
# -----------------------------------
test:
override:
- make clean
- make glide
- make setup
- make tests
- make cover
- make build
- make ember
- docker build -t abcum/surreal .
- docker run -d abcum/surreal start; sleep 15
# -----------------------------------
deployment:
deploy:
branch: master
commands:
- docker push abcum/surreal