Skip to content

Commit

Permalink
Simply CircleCI config
Browse files Browse the repository at this point in the history
Signed-off-by: Dave Tucker <[email protected]>
  • Loading branch information
Dave Tucker committed May 3, 2016
1 parent 139587a commit f1c0ee4
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 28 deletions.
6 changes: 5 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.PHONY: all test test-local install-deps lint fmt vet
.PHONY: all test test-local test-ci install-deps lint fmt vet

all: test

Expand All @@ -9,6 +9,10 @@ test-local: install-deps fmt lint vet
test:
@docker-compose run --rm test

# Because CircleCI fails to rm a container
test-ci:
@docker-compose run test

install-deps:
@echo "+ $@"
@go get -u github.com/golang/lint/golint
Expand Down
29 changes: 2 additions & 27 deletions circle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,36 +2,11 @@
machine:
services:
- docker
environment:
DOCKER_IP: "127.0.0.1"
GOPATH: "/home/ubuntu/.go_workspace"
ORG_PATH: "github.com/socketplane"
REPO_PATH: "${ORG_PATH}/libovsdb"

dependencies:
override:
- rm -rf ${GOPATH}/src/${REPO_PATH}
- mkdir -p ${GOPATH}/src/${ORG_PATH}
- cp -r ../libovsdb ${GOPATH}/src/${ORG_PATH}
- mkdir -p ${CIRCLE_ARTIFACTS}/coverage
- go get github.com/mattn/goveralls
- echo "Nothing to see here.."

post:
- sudo pip install -qq fig:
pwd: ../.go_workspace/src/${REPO_PATH}
- fig up -d:
pwd: ../.go_workspace/src/${REPO_PATH}
test:
override:
- make build:
pwd: ../.go_workspace/src/${REPO_PATH}
- make test-all:
pwd: ../.go_workspace/src/${REPO_PATH}
post:
- fig stop:
pwd: ../.go_workspace/src/${REPO_PATH}
- go tool cover -html=coverage.out -o $CIRCLE_ARTIFACTS/coverage/index.html:
pwd: ../.go_workspace/src/${REPO_PATH}
- goveralls -coverprofile=coverage.out -service=circleci -repotoken $COVERALLS_TOKEN:
pwd: ../.go_workspace/src/${REPO_PATH}

- make test-ci

0 comments on commit f1c0ee4

Please sign in to comment.