File tree 2 files changed +3
-4
lines changed
2 files changed +3
-4
lines changed Original file line number Diff line number Diff line change 15
15
working_directory : /go/src/github.com/appvia/aws_usersync
16
16
steps :
17
17
- checkout
18
- - run : go get github.com/mitchellh/gox
19
18
- run : go get github.com/tcnksm/ghr
20
19
- run : mkdir ./bin
21
- - run : gox -osarch="linux/amd64" -output=./bin/$CIRCLE_PROJECT_REPONAME-$CIRCLE_TAG
20
+ - run : make static
22
21
- run : git config --global user.name jon-shanks
23
22
- run : ghr $CIRCLE_TAG ./bin/
24
23
Original file line number Diff line number Diff line change @@ -6,7 +6,7 @@ ROOT_DIR=${PWD}
6
6
HARDWARE =$(shell uname -m)
7
7
GIT_SHA =$(shell git --no-pager describe --always --dirty)
8
8
BUILD_TIME =$(shell date -u '+% Y-% m-% d_% I:% M:% S% p')
9
- VERSION ?= $(shell awk '/Version .* =/ { print $$3 }' cmd/aws_usersync/main.go | sed 's/"//g')
9
+ VERSION ?= $(shell awk '/version .* =/ { print $$3 }' cmd/aws_usersync/main.go | sed 's/"//g')
10
10
DEPS =$(shell go list -f '{{range .TestImports}}{{.}} {{end}}' ./...)
11
11
PACKAGES =$(shell go list ./...)
12
12
LFLAGS ?= -X main.GitSHA=${GIT_SHA}
32
32
static : golang deps
33
33
@echo " --> Compiling the static binary"
34
34
mkdir -p bin
35
- CGO_ENABLED=0 GOOS=linux go build -a -tags netgo -ldflags " -w ${LFLAGS} " -o bin/${NAME} cmd/${NAME} /* .go
35
+ CGO_ENABLED=0 GOOS=linux go build -a -tags netgo -ldflags " -w ${LFLAGS} " -o bin/${NAME} - ${VERSION} -linux-amd64 cmd/${NAME} /* .go
36
36
37
37
docker-release :
38
38
@echo " --> Building a release image"
You can’t perform that action at this time.
0 commit comments