Skip to content

Commit b4c66de

Browse files
authored
🐛 Replace one last CONTAINER_RUNTIME in make (#782)
* Replace one last CONTAINER_RUNTIME in make * Workaround for podman for kind load
1 parent 189b42a commit b4c66de

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

Makefile

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,15 @@ e2e-coverage:
151151

152152
.PHONY: kind-load
153153
kind-load: $(KIND) #EXHELP Loads the currently constructed image onto the cluster.
154+
ifeq ($(CONTAINER_RUNTIME),podman)
155+
@echo "Using Podman"
156+
podman save $(IMG) -o $(IMG).tar
157+
$(KIND) load image-archive $(IMG).tar --name $(KIND_CLUSTER_NAME)
158+
rm $(IMG).tar
159+
else
160+
@echo "Using Docker"
154161
$(KIND) load docker-image $(IMG) --name $(KIND_CLUSTER_NAME)
162+
endif
155163

156164
kind-deploy: export MANIFEST="./operator-controller.yaml"
157165
kind-deploy: manifests $(KUSTOMIZE) #EXHELP Install controller and dependencies onto the kind cluster.
@@ -215,7 +223,7 @@ run: docker-build kind-cluster kind-load kind-deploy #HELP Build the operator-co
215223

216224
.PHONY: docker-build
217225
docker-build: build-linux #EXHELP Build docker image for operator-controller with GOOS=linux and local GOARCH.
218-
docker build -t ${IMG} -f Dockerfile ./bin/linux
226+
$(CONTAINER_RUNTIME) build -t ${IMG} -f Dockerfile ./bin/linux
219227

220228
#SECTION Release
221229

0 commit comments

Comments
 (0)