Compress the packed static js and css to save some space.

This commit is contained in:
Eugene Bujak 2018-11-29 19:40:48 +03:00
parent e0286ee85d
commit 9089122b56
1 changed files with 5 additions and 2 deletions

View File

@ -20,8 +20,11 @@ $(STATIC): $(JSFILES) client/node_modules
npm --prefix client run build-prod npm --prefix client run build-prod
$(TARGET): $(STATIC) *.go coredns_plugin/*.go dnsfilter/*.go $(TARGET): $(STATIC) *.go coredns_plugin/*.go dnsfilter/*.go
GOPATH=$(GOPATH) GOOS=$(NATIVE_GOOS) GOARCH=$(NATIVE_GOARCH) GO111MODULE=off go get -v github.com/gobuffalo/packr/... go get -d .
GOPATH=$(GOPATH) PATH=$(GOPATH)/bin:$(PATH) packr build -ldflags="-X main.VersionString=$(GIT_VERSION)" -asmflags="-trimpath=$(PWD)" -gcflags="-trimpath=$(PWD)" -o $(TARGET) GOOS=$(NATIVE_GOOS) GOARCH=$(NATIVE_GOARCH) GO111MODULE=off go get -v github.com/gobuffalo/packr/...
PATH=$(GOPATH)/bin:$(PATH) packr -z
CGO_ENABLED=0 go build -ldflags="-s -w -X main.VersionString=$(GIT_VERSION)" -asmflags="-trimpath=$(PWD)" -gcflags="-trimpath=$(PWD)" -o $(TARGET)
PATH=$(GOPATH)/bin:$(PATH) packr clean
clean: clean:
$(MAKE) cleanfast $(MAKE) cleanfast