@@ -27,14 +27,11 @@ CWD := $(abspath .)
2727SHELL := hack/shell-with-gopath.sh
2828
2929# Image URL to use all building/pushing image targets
30- PRODUCTION_IMG ?= gcr.io/cnx-cluster-api/vsphere-cluster-api-provider:0.3.0
3130CI_IMG ?= gcr.io/cnx-cluster-api/vsphere-cluster-api-provider
3231CLUSTERCTL_CI_IMG ?= gcr.io/cnx-cluster-api/clusterctl
33- DEV_IMG ?= # <== NOTE: outside dev, change this!!!
3432
3533# Retrieves the git hash
36- VERSION ?= $(shell git describe --exact-match 2> /dev/null || \
37- git describe --match=$(git rev-parse --short=8 HEAD ) --always --dirty --abbrev=8)
34+ VERSION ?= $(shell git describe --always --dirty)
3835
3936# Build manager binary
4037manager : check
@@ -92,52 +89,10 @@ vendor:
9289 cp -rf --no-preserve=mode " $$ {_src}" " $$ {_dst}"
9390.PHONY : vendor
9491
95- # ###################################
96- # DEVELOPMENT Build and Push targets
97- # ###################################
98-
99- # Create YAML file for deployment
100- dev-yaml :
101- CAPV_MANAGER_IMAGE=$(DEV_IMG ) hack/generate-yaml.sh
102-
103- # Build the docker image
104- dev-build : # test
105- docker build . -t $(DEV_IMG )
106-
107- # Push the docker image
108- dev-push :
109- docker push $(DEV_IMG )
110-
111- .PHONY : dev-yaml dev-build dev-push
112-
113- # ##################################
114- # PRODUCTION Build and Push targets
115- # ##################################
116-
117- # Create YAML file for deployment
118- prod-yaml :
119- CAPV_MANAGER_IMAGE=$(PRODUCTION_IMG ) hack/generate-yaml.sh
120-
121- # Build the docker image
122- prod-build : test
123- docker build . -t $(PRODUCTION_IMG )
124-
125- # Push the docker image
126- prod-push :
127- @echo " logging into gcr.io registry with key file"
128- @docker login -u _json_key --password-stdin gcr.io < " $( GCR_KEY_FILE) "
129- docker push $(PRODUCTION_IMG )
130-
131- .PHONY : prod-yaml prod-build prod-push
132-
13392# ##################################
13493# CI Build and Push targets
13594# ##################################
13695
137- # Create YAML file for deployment into CI
138- ci-yaml :
139- CAPV_MANAGER_IMAGE=$(CI_IMG ) hack/generate-yaml.sh
140-
14196ci-image : generate fmt vet manifests
14297 docker build . -t " $( CI_IMG) :$( VERSION) "
14398 docker build . -f cmd/clusterctl/Dockerfile -t " $( CLUSTERCTL_CI_IMG) :$( VERSION) "
0 commit comments