Skip to content

Commit 9a8ed16

Browse files
committed
fix(ci): parameterize KIND_CLUSTER_NAME to support CI 'local' cluster
1 parent 38b3eaa commit 9a8ed16

2 files changed

Lines changed: 3 additions & 5 deletions

File tree

.github/workflows/test-k8s-deployment.yaml

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -229,10 +229,7 @@ jobs:
229229

230230
- name: Build and Load Test Runner Image
231231
run: |
232-
make build-test-runner
233-
# The make target uses v3, but runner uses v4. Let's tag it v4 to match test-runner.ts
234-
docker tag constructive/function-test-runner:v3 constructive/function-test-runner:v4
235-
kind load docker-image constructive/function-test-runner:v4 --name local
232+
make build-test-runner KIND_CLUSTER_NAME=local
236233
237234
- name: Run K8s Tests
238235
run: |

Makefile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ KIND_BIN := $(shell which kind)
66
ifeq ($(KIND_BIN),)
77
KIND_BIN := /opt/homebrew/bin/kind
88
endif
9+
KIND_CLUSTER_NAME ?= interweb-local
910

1011
SUBDIRS := functions/hello-world functions/simple-email functions/send-email-link functions/runtime-script
1112

@@ -61,7 +62,7 @@ test-k8s-all:
6162
build-test-runner:
6263
@echo "Building Shared Test Runner Image..."
6364
docker build -f functions/_runtimes/node/Dockerfile.test -t constructive/function-test-runner:v4 .
64-
$(KIND_BIN) load docker-image constructive/function-test-runner:v4 --name interweb-local
65+
$(KIND_BIN) load docker-image constructive/function-test-runner:v4 --name $(KIND_CLUSTER_NAME)
6566

6667
# Individual Test Shortcuts
6768
test-calvin:

0 commit comments

Comments
 (0)