From b48ab6a313593cac0ec57838357ef1f78d3f1a2e Mon Sep 17 00:00:00 2001 From: fabriziopandini Date: Fri, 3 Feb 2023 14:58:55 +0100 Subject: [PATCH 1/2] add few gitignore patterns --- .gitignore | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index 8da5c0f6dbb..17b0da92b66 100644 --- a/.gitignore +++ b/.gitignore @@ -5,8 +5,17 @@ contrib/demo/clusters/kind/*.kubeconfig coverage.* tools build -.vscode # JetBrains IDE files .idea/ *.iml + +# VSCode +.vscode/ +*.code-workspace + +# Common editor / temporary files +.DS_Store + +# Folder where each developer can store temporary files +tmp From a43bada412b17276a8db202d8e0552b377882706 Mon Sep 17 00:00:00 2001 From: fabriziopandini Date: Mon, 6 Feb 2023 18:11:47 +0100 Subject: [PATCH 2/2] add support for specifying KIND_CLUSTER_NAME make when running build-kind-images --- Makefile | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index c8039c75637..d8d9d28838c 100644 --- a/Makefile +++ b/Makefile @@ -22,6 +22,7 @@ TOOLS_GOBIN_DIR := $(abspath $(TOOLS_DIR)) GOBIN_DIR=$(abspath ./bin) PATH := $(GOBIN_DIR):$(TOOLS_GOBIN_DIR):$(PATH) TMPDIR := $(shell mktemp -d) +KIND_CLUSTER_NAME ?= kind # Detect the path used for the install target ifeq (,$(shell go env GOBIN)) @@ -114,11 +115,11 @@ build-all: .PHONY: build-kind-images build-kind-images-ko: require-ko - $(eval SYNCER_IMAGE=$(shell KO_DOCKER_REPO=kind.local ko build --platform=linux/$(ARCH) ./cmd/syncer)) - $(eval TEST_IMAGE=$(shell KO_DOCKER_REPO=kind.local ko build --platform=linux/$(ARCH) ./test/e2e/fixtures/kcp-test-image)) + $(eval SYNCER_IMAGE=$(shell KO_DOCKER_REPO=kind.local KIND_CLUSTER_NAME=$(KIND_CLUSTER_NAME) ko build --platform=linux/$(ARCH) ./cmd/syncer)) + $(eval TEST_IMAGE=$(shell KO_DOCKER_REPO=kind.local KIND_CLUSTER_NAME=$(KIND_CLUSTER_NAME) ko build --platform=linux/$(ARCH) ./test/e2e/fixtures/kcp-test-image)) build-kind-images: build-kind-images-ko - test -n "$(SYNCER_IMAGE)" || (echo Failed to create syncer image; exit 1) - test -n "$(TEST_IMAGE)" || (echo Failed to create test image; exit 1) + @test -n "$(SYNCER_IMAGE)" && (echo $(SYNCER_IMAGE) pushed to "$(KIND_CLUSTER_NAME)" kind cluster) || (echo Failed to create syncer image and/or to push it to "$(KIND_CLUSTER_NAME)" kind cluster; exit 1) + @test -n "$(TEST_IMAGE)" && (echo $(TEST_IMAGE) pushed to "$(KIND_CLUSTER_NAME)" kind cluster) || (echo Failed to create test image and and/or to push it to "$(KIND_CLUSTER_NAME)" kind cluster; exit 1) install: WHAT ?= ./cmd/... install: