From 08dd47d9547c2d3ad0cf40760288e3195538005f Mon Sep 17 00:00:00 2001 From: Adrian Macneil Date: Sat, 21 May 2016 20:01:49 -0700 Subject: [PATCH] Create slimmer go binaries --- Makefile | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 867ab8d..dc08031 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,5 @@ DC := docker-compose +BUILD_FLAGS := -ldflags '-s' all: clean container lint test build @@ -17,5 +18,5 @@ test: $(DC) run dbmate go test -v build: clean - $(DC) run -e GOARCH=386 dbmate go build -o dist/dbmate-linux-i386 - $(DC) run -e GOARCH=amd64 dbmate go build -o dist/dbmate-linux-amd64 + $(DC) run -e GOARCH=386 dbmate go build $(BUILD_FLAGS) -o dist/dbmate-linux-i386 + $(DC) run -e GOARCH=amd64 dbmate go build $(BUILD_FLAGS) -o dist/dbmate-linux-amd64