File tree Expand file tree Collapse file tree 2 files changed +12
-0
lines changed Expand file tree Collapse file tree 2 files changed +12
-0
lines changed Original file line number Diff line number Diff line change @@ -4,6 +4,9 @@ services:
44- docker
55go :
66- " 1.10"
7+ script :
8+ - echo "Nginx ASG sync - commit:${TRAVIS_COMMIT}"
9+ - make BUILD_IN_CONTAINER=0 all
710before_install :
811- echo "PR Slug:${TRAVIS_PULL_REQUEST_SLUG}"
912- if [[ "${TRAVIS_PULL_REQUEST_SLUG}" == "nginxinc/nginx-asg-sync" || "${TRAVIS_PULL_REQUEST}" == "false" ]]; then
Original file line number Diff line number Diff line change 11GO_DOCKER_RUN = docker run --rm -v $(shell pwd) :/go/src/github.com/nginxinc/nginx-asg-sync -v $(shell pwd) /build_output:/build_output -w /go/src/github.com/nginxinc/nginx-asg-sync/cmd/sync
22GOLANG_CONTAINER = golang:1.10
3+ BUILD_IN_CONTAINER = 1
34
45all : amazon centos7 ubuntu-trusty ubuntu-xenial
56
67test :
8+ ifeq ($(BUILD_IN_CONTAINER ) ,1)
79 $(GO_DOCKER_RUN) $(GOLANG_CONTAINER) go test
10+ else
11+ go test ./...
12+ endif
813
914compile : test
15+ ifeq ($(BUILD_IN_CONTAINER ) ,1)
1016 $(GO_DOCKER_RUN) $(GOLANG_CONTAINER) go build -o /build_output/nginx-asg-sync
17+ else
18+ go build -o ./build_output/nginx-asg-sync github.com/nginxinc/nginx-asg-sync/cmd/sync
19+ endif
1120
1221amazon : compile
1322 make -C build/package/builders/amazon/
You can’t perform that action at this time.
0 commit comments