Skip to content

Commit 0d452d4

Browse files
committed
Adds image-load and kind-load Make targets
Signed-off-by: Daneyon Hansen <[email protected]>
1 parent d5f5507 commit 0d452d4

File tree

1 file changed

+17
-4
lines changed

1 file changed

+17
-4
lines changed

Makefile

+17-4
Original file line numberDiff line numberDiff line change
@@ -133,28 +133,41 @@ verify: vet fmt-verify manifests generate ci-lint
133133

134134
# Build the container image
135135
.PHONY: image-local-build
136-
image-local-build:
136+
image-local-build: ## Build the EPP image for local development.
137137
BUILDER=$(shell $(DOCKER_BUILDX_CMD) create --use)
138138
$(MAKE) image-build PUSH=$(PUSH)
139+
$(MAKE) image-build LOAD=$(LOAD)
139140
$(DOCKER_BUILDX_CMD) rm $$BUILDER
140141

141142
.PHONY: image-local-push
142-
image-local-push: PUSH=--push
143+
image-local-push: PUSH=--push ## Build the EPP image for local development and push it to $IMAGE_REPO.
143144
image-local-push: image-local-build
144145

146+
.PHONY: image-local-load
147+
image-local-load: LOAD=--load ## Build and load the EPP image into the local Docker registry.
148+
image-local-load: image-local-build
149+
145150
.PHONY: image-build
146-
image-build:
151+
image-build: ## Build the EPP image using Docker Buildx.
147152
$(IMAGE_BUILD_CMD) -t $(IMAGE_TAG) \
148153
--platform=$(PLATFORMS) \
149154
--build-arg BASE_IMAGE=$(BASE_IMAGE) \
150155
--build-arg BUILDER_IMAGE=$(BUILDER_IMAGE) \
151156
$(PUSH) \
157+
$(LOAD) \
152158
$(IMAGE_BUILD_EXTRA_OPTS) ./
153159

154160
.PHONY: image-push
155-
image-push: PUSH=--push
161+
image-push: PUSH=--push ## Build the EPP image using Docker Buildx and push it to $IMAGE_REPO.
156162
image-push: image-build
157163

164+
.PHONY: image-load
165+
image-load: LOAD=--load ## Build and load the EPP image without additional local build steps.
166+
image-load: image-build
167+
168+
.PHONY: kind-load
169+
kind-load: image-build ## Build and load the EPP image to a kind cluster.
170+
kind load docker-image $(IMAGE_TAG)
158171

159172
##@ Docs
160173

0 commit comments

Comments
 (0)