From 00484701bbf585681fd71bbe57b76e191f7e79ba Mon Sep 17 00:00:00 2001 From: Berk Gokden Date: Mon, 8 Apr 2019 11:49:53 +0200 Subject: [PATCH] Add support for alpine build (#11) --- .circleci/config.yml | 1 + build.sh | 4 ++-- cmd/root.go | 2 +- install.sh | 2 +- 4 files changed, 5 insertions(+), 4 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 54ca216..2a0485e 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -12,6 +12,7 @@ jobs: - run: ./build.sh local - run: cp ./bin/* ./artifacts - run: cp ./bin/vamp-darwin-amd64 ./artifacts/vamp-darwin-x86_64 + - run: cp ./bin/vamp-linux-amd64 ./artifacts/vamp-linux-x86_64 - run: go run main.go version clean > ./artifacts/version.txt - persist_to_workspace: root: ./artifacts diff --git a/build.sh b/build.sh index 2d11712..d78e5bf 100755 --- a/build.sh +++ b/build.sh @@ -13,7 +13,7 @@ if [ "$1" = "local" ]; then if [ "$GOOS" = "windows" ]; then go get -u github.com/spf13/cobra fi - go build -o bin/vamp-$GOOS-$GOARCH + CGO_ENABLED=0 go build -o bin/vamp-$GOOS-$GOARCH done done unset GOOS @@ -28,7 +28,7 @@ else if [ "$GOOS" = "windows" ]; then go get -u github.com/spf13/cobra fi - go build -o bin/vamp-$GOOS-$GOARCH + CGO_ENABLED=0 go build -o bin/vamp-$GOOS-$GOARCH done done ' diff --git a/cmd/root.go b/cmd/root.go index ba3d7fa..4b37b2b 100644 --- a/cmd/root.go +++ b/cmd/root.go @@ -58,7 +58,7 @@ var OutputType string var Hosts []string // version should be in format d.d.d where d is a decimal number -const Version string = "0.0.19" +const Version string = "0.0.20" const AppName string = "vamp" // Backend version is the version this client is tested with diff --git a/install.sh b/install.sh index 126e838..7d57cba 100755 --- a/install.sh +++ b/install.sh @@ -1,4 +1,4 @@ #!/usr/bin/env bash mkdir -p $GOPATH/bin -go build -o $GOPATH/bin/vamp +CGO_ENABLED=0 go build -o $GOPATH/bin/vamp