File tree Expand file tree Collapse file tree 1 file changed +12
-1
lines changed Expand file tree Collapse file tree 1 file changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -199,7 +199,18 @@ HELM_BIN := helm
199199HELM := $(TOOLS_BIN_DIR ) /$(HELM_BIN ) -$(HELM_VER )
200200
201201# Define Docker related variables. Releases should modify and double check these vars.
202- REGISTRY ?= gcr.io/$(shell gcloud config get-value project)
202+ ifneq ($(shell command -v gcloud) ,)
203+ GCLOUD_PROJECT := $(shell gcloud config get-value project 2>/dev/null)
204+ ifneq ($(GCLOUD_PROJECT),)
205+ REGISTRY ?= gcr.io/$(GCLOUD_PROJECT)
206+ endif
207+ endif
208+
209+ # If REGISTRY is not set, default to localhost:5000 to use the kind registry.
210+ ifndef REGISTRY
211+ REGISTRY ?= localhost:5000
212+ endif
213+
203214PROD_REGISTRY ?= registry.k8s.io/cluster-api-helm
204215
205216STAGING_REGISTRY ?= gcr.io/k8s-staging-cluster-api-helm
You can’t perform that action at this time.
0 commit comments