From 31a90c76c41220b6d1e0de1ae44ade3a0fd15331 Mon Sep 17 00:00:00 2001 From: Tom Wilkie Date: Wed, 13 Apr 2016 13:29:34 +0100 Subject: [PATCH 1/2] Update to go 1.6.1 --- backend/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/Dockerfile b/backend/Dockerfile index db2659c77..3a4910413 100644 --- a/backend/Dockerfile +++ b/backend/Dockerfile @@ -1,4 +1,4 @@ -FROM golang:1.6.0 +FROM golang:1.6.1 RUN apt-get update && \ apt-get install -y libpcap-dev python-requests time file && \ rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* From 8f03b67ade9d9b0121dc93d866d3fbd5dcc84bdf Mon Sep 17 00:00:00 2001 From: Tom Wilkie Date: Mon, 18 Apr 2016 15:28:41 +0100 Subject: [PATCH 2/2] Add -s & -w flags to omit various symbol tables from the binary. This does not effect backtraces. Before the scope binary was 49M, now its 32M. For more detauls, see https://blog.filippo.io/shrink-your-go-binaries-with-this-one-weird-trick/ --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 34521d84c..891b50b32 100644 --- a/Makefile +++ b/Makefile @@ -29,7 +29,7 @@ GO_HOST=$(NO_CROSS_COMP); $(GO) WITH_GO_HOST_ENV=$(NO_CROSS_COMP); $(GO_ENV) GO_BUILD_INSTALL_DEPS=-i GO_BUILD_TAGS='netgo unsafe' -GO_BUILD_FLAGS=$(GO_BUILD_INSTALL_DEPS) -ldflags "-extldflags \"-static\" -X main.version=$(SCOPE_VERSION)" -tags $(GO_BUILD_TAGS) +GO_BUILD_FLAGS=$(GO_BUILD_INSTALL_DEPS) -ldflags "-extldflags \"-static\" -X main.version=$(SCOPE_VERSION) -s -w" -tags $(GO_BUILD_TAGS) all: $(SCOPE_EXPORT)