-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Set
GOBIN
so Makefile don't modify $PATH on go install
Fix realPath resolving when cloud credentials is prefixed by `~` for home dir Use `~/.docker/config.json` if REGISTRY_CREDENTIAL_FILE not defined and skip step if does not exists since it is optional Signed-off-by: Tiger Kaovilai <[email protected]>
- Loading branch information
Showing
8 changed files
with
51 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -41,8 +41,10 @@ help: ## Display this help | |
|
||
TOOLS_DIR := $(REPO_ROOT)/hack/tools | ||
BIN_DIR := bin | ||
# Try to not modify PATH if possible | ||
GOBIN := $(REPO_ROOT)/.go/bin | ||
TOOLS_BIN_DIR := $(TOOLS_DIR)/$(BIN_DIR) | ||
GINKGO := $(shell go env GOPATH)/bin/ginkgo | ||
GINKGO := $(GOBIN)/ginkgo | ||
KUSTOMIZE := $(TOOLS_BIN_DIR)/kustomize | ||
OUTPUT_DIR := _output/$(GOOS)/$(GOARCH)/bin | ||
GINKGO_FOCUS ?= | ||
|
@@ -106,10 +108,13 @@ SNAPSHOT_MOVE_DATA ?= false | |
DATA_MOVER_PLUGIN ?= | ||
DISABLE_INFORMER_CACHE ?= false | ||
|
||
|
||
# Make sure ginkgo is in $GOBIN | ||
.PHONY:ginkgo | ||
ginkgo: # Make sure ginkgo is in $GOPATH/bin | ||
go install github.com/onsi/ginkgo/[email protected] | ||
ginkgo: ${GOBIN}/ginkgo | ||
|
||
# This target does not run if ginkgo is already in $GOBIN | ||
${GOBIN}/ginkgo: | ||
GOBIN=${GOBIN} go install github.com/onsi/ginkgo/[email protected] | ||
|
||
.PHONY: run | ||
run: ginkgo | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -41,8 +41,10 @@ help: ## Display this help | |
|
||
TOOLS_DIR := $(REPO_ROOT)/hack/tools | ||
BIN_DIR := bin | ||
# Try to not modify PATH if possible | ||
GOBIN := $(REPO_ROOT)/.go/bin | ||
TOOLS_BIN_DIR := $(TOOLS_DIR)/$(BIN_DIR) | ||
GINKGO := $(GOPATH)/bin/ginkgo | ||
GINKGO := $(GOBIN)/ginkgo | ||
KUSTOMIZE := $(TOOLS_BIN_DIR)/kustomize | ||
OUTPUT_DIR := _output/$(GOOS)/$(GOARCH)/bin | ||
GINKGO_FOCUS ?= | ||
|
@@ -88,9 +90,13 @@ VELERO_POD_CPU_REQUEST ?= 2 | |
VELERO_POD_MEM_REQUEST ?= 2Gi | ||
POD_VOLUME_OPERATION_TIMEOUT ?= 6h | ||
|
||
# Make sure ginkgo is in $GOBIN | ||
.PHONY:ginkgo | ||
ginkgo: # Make sure ginkgo is in $GOPATH/bin | ||
go install github.com/onsi/ginkgo/[email protected] | ||
ginkgo: ${GOBIN}/ginkgo | ||
|
||
# This target does not run if ginkgo is already in $GOBIN | ||
${GOBIN}/ginkgo: | ||
GOBIN=${GOBIN} go install github.com/onsi/ginkgo/[email protected] | ||
|
||
.PHONY: run | ||
run: ginkgo | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters