Skip to content

Commit 9d5bc45

Browse files
committed
Add targets for local e2e controller
1 parent 64bc0d8 commit 9d5bc45

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

Makefile

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
# Image URL to use all building/pushing image targets
22
IMG_NAME ?= ghcr.io/metal-stack/cluster-api-metal-stack-controller
33
IMG_TAG ?= latest
4+
IMG_TAG_E2E ?= e2e
45
IMG ?= ${IMG_NAME}:${IMG_TAG}
6+
IMG_E2E ?= ${IMG_NAME}:${IMG_TAG_E2E}
57
# ENVTEST_K8S_VERSION refers to the version of kubebuilder assets to be downloaded by envtest binary.
68
ENVTEST_K8S_VERSION = 1.31.0
79
RELEASE_DIR ?= .release
@@ -204,6 +206,10 @@ docker-build: ## Build docker image with the manager.
204206
docker-push: ## Push docker image with the manager.
205207
$(CONTAINER_TOOL) push ${IMG}
206208

209+
.PHONY: docker-build-e2e
210+
docker-build-e2e:
211+
$(CONTAINER_TOOL) build -t ${IMG_E2E} .
212+
207213
# PLATFORMS defines the target platforms for the manager image be built to provide support to multiple
208214
# architectures. (i.e. make docker-buildx IMG=myregistry/mypoperator:0.0.1). To use this option you need to:
209215
# - be able to use docker buildx. More info: https://docs.docker.com/build/buildx/
@@ -227,6 +233,12 @@ build-installer: manifests generate kustomize ## Generate a consolidated YAML wi
227233
cd config/manager && $(KUSTOMIZE) edit set image controller=${IMG_NAME}:${IMG_TAG}
228234
$(KUSTOMIZE) build config/default > $(RELEASE_DIR)/install.yaml
229235

236+
.PHONY: build-installer-e2e
237+
build-installer-e2e: manifests generate kustomize ## Generate a consolidated YAML with CRDs and deployment.
238+
mkdir -p $(RELEASE_DIR)
239+
cd config/manager && $(KUSTOMIZE) edit set image controller=${IMG_NAME}:${IMG_TAG_E2E}
240+
$(KUSTOMIZE) build config/default > $(RELEASE_DIR)/install.yaml
241+
230242
##@ Deployment
231243

232244
ifndef ignore-not-found

0 commit comments

Comments
 (0)