Skip to content

Commit

Permalink
Makefile: use goproxy to download dependent golang package
Browse files Browse the repository at this point in the history
Signed-off-by: ywc689 <[email protected]>
  • Loading branch information
ywc689 committed Jan 15, 2025
1 parent ccb57ea commit 76f7071
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
5 changes: 4 additions & 1 deletion tools/dpvs-agent/cmd/dpvs-agent-server/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,17 @@ RM = rm

all: $(TARGET)

$(TARGET):
$(TARGET): go-proxy
-$(GO) mod tidy
$(GO_BUILD) -o $@

clean:
$(GO_CLEAN)
-$(RM) $(TARGET)

go-proxy:
$(GO) env -w GOPROXY=https://goproxy.cn,direct

install: $(TARGET)
$(INSTALL) -m 0755 -d $(INSDIR)
$(INSTALL) -m 0744 $(TARGET) $(INSDIR)
Expand Down
5 changes: 4 additions & 1 deletion tools/healthcheck/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,13 @@ GO_CLEAN = $(GO) clean

all: $(TARGET)

$(TARGET):
$(TARGET): go-proxy
-$(GO) mod tidy
$(GO_BUILD) -o $@

go-proxy:
$(GO) env -w GOPROXY=https://goproxy.cn,direct

clean:
$(GO_CLEAN)

Expand Down

0 comments on commit 76f7071

Please sign in to comment.