From bd892caba08e27914c9e230aa40cb1356293eb99 Mon Sep 17 00:00:00 2001 From: fserucas Date: Tue, 7 Nov 2023 10:55:48 +0000 Subject: [PATCH] Set Golang Environment Variable This tackles the commit change at https://github.com/nmstate/nmstate/commit/661ffd89520cff765a9dd90559efebe2171b1b48 Change-Id: Ie2ecaecb2eaeefeab25253ff721eee348c82886f --- Makefile | 6 +++++- tools/sfconfig | 1 + 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index c4ad9adc..35b74d8b 100644 --- a/Makefile +++ b/Makefile @@ -83,8 +83,12 @@ dev-deployment: ##@ Build +.PHONY: setenv +setenv: + go env -w GOSUMDB="sum.golang.org" GOPROXY="https://proxy.golang.org,direct" + .PHONY: build -build: generate fmt vet sc build-api-doc ## Build manager binary. +build: setenv generate fmt vet sc build-api-doc ## Build manager binary. go build -o bin/manager main.go .PHONY: build-api-doc diff --git a/tools/sfconfig b/tools/sfconfig index db059ff5..3cbaa032 100755 --- a/tools/sfconfig +++ b/tools/sfconfig @@ -1,3 +1,4 @@ #!/bin/bash +go env -w GOSUMDB="sum.golang.org" GOPROXY="https://proxy.golang.org,direct" go run cli/sfconfig/main.go $*