File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -2,6 +2,8 @@ IMG_USER ?= netobserv
22TAG ?= dev
33BUILD_VERSION := $(shell git describe --long HEAD)
44BUILD_DATE := $(shell date +% Y-% m-% d\ % H:% M)
5+ # You can add GO Build flags like -gcflags=all="-N -l" here to remove optimizations for debugging
6+ BUILD_FLAGS ?= -ldflags "-X 'main.buildVersion=${BUILD_VERSION}' -X 'main.buildDate=${BUILD_DATE}'"
57BUILD_SHA := $(shell git rev-parse --short HEAD)
68
79BASE_IMAGE ?= quay.io/${IMG_USER}/network-observability-console-plugin
@@ -82,7 +84,7 @@ test: test-backend test-frontend
8284.PHONY : build-backend
8385build-backend : fmt-backend
8486 @echo " ### Building backend"
85- go build -gcflags= ' -N -l ' -ldflags " -X 'main.buildVersion= ${BUILD_VERSION} ' -X 'main.buildDate= ${BUILD_DATE} ' " -mod vendor -o plugin-backend cmd/plugin-backend.go
87+ go build ${BUILD_FLAGS} -mod vendor -o plugin-backend cmd/plugin-backend.go
8688
8789.PHONY : build-frontend
8890build-frontend : install-frontend fmt-frontend
You can’t perform that action at this time.
0 commit comments