File tree Expand file tree Collapse file tree 2 files changed +4
-3
lines changed Expand file tree Collapse file tree 2 files changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -12,4 +12,4 @@ before_install:
12
12
- if [[ "${TRAVIS_PULL_REQUEST_SLUG}" == "nginxinc/nginx-asg-sync" || "${TRAVIS_PULL_REQUEST}" == "false" ]]; then
13
13
wget https://github.com/fossas/fossa-cli/releases/download/v1.0.27/fossa-cli_1.0.27_linux_amd64.tar.gz && tar xzf fossa-cli_1.0.27_linux_amd64.tar.gz
14
14
&& ./fossa init
15
- && FOSSA_API_KEY=${fossapush} ./fossa analyze -t nginx-asg-sync -b ${TRAVIS_BRANCH} ; fi
15
+ && GO111MODULE=on FOSSA_API_KEY=${fossapush} ./fossa analyze -t nginx-asg-sync -b ${TRAVIS_BRANCH} ; fi
Original file line number Diff line number Diff line change 1
1
GO_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
2
2
GOLANG_CONTAINER = golang:1.14
3
3
BUILD_IN_CONTAINER = 1
4
+ GOFLAGS ?= -mod=vendor
4
5
5
6
all : amazon centos7 ubuntu-xenial amazon2 ubuntu-bionic
6
7
7
8
test :
8
9
ifeq ($(BUILD_IN_CONTAINER ) ,1)
9
10
$(GO_DOCKER_RUN) $(GOLANG_CONTAINER) go test
10
11
else
11
- go test ./...
12
+ GO111MODULE=on GOFLAGS='$(GOFLAGS)' go test ./...
12
13
endif
13
14
14
15
lint :
@@ -18,7 +19,7 @@ compile: test
18
19
ifeq ($(BUILD_IN_CONTAINER ) ,1)
19
20
$(GO_DOCKER_RUN) $(GOLANG_CONTAINER) go build -o /build_output/nginx-asg-sync
20
21
else
21
- go build -o ./build_output/nginx-asg-sync github.com/nginxinc/nginx-asg-sync/cmd/sync
22
+ GO111MODULE=on GOFLAGS='$(GOFLAGS)' go build -o ./build_output/nginx-asg-sync github.com/nginxinc/nginx-asg-sync/cmd/sync
22
23
endif
23
24
24
25
amazon : compile
You can’t perform that action at this time.
0 commit comments