You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Apr 24, 2024. It is now read-only.
touch $(KUSTOMIZE)# we download an "old" file, so make will re-download to refresh it unless we make it newer than the owning dir
42
+
43
+
$(CONTROLLER_GEN): ## Download controller-gen locally if necessary.
44
+
mkdir -p $(LOCALBIN)
45
+
GOBIN=$(LOCALBIN) go install sigs.k8s.io/controller-tools/cmd/controller-gen@$(CONTROLLER_TOOLS_VERSION)
46
+
47
+
$(YQ): ## Download yq locally if necessary.
48
+
mkdir -p $(LOCALBIN)
49
+
GOBIN=$(LOCALBIN) go install github.com/mikefarah/yq/v4@$(YQ_VERSION)
50
+
51
+
OS ?= $(shell go env GOOS )
52
+
ARCH ?= $(shell go env GOARCH )
53
+
54
+
$(KCP): ## Download kcp locally if necessary.
55
+
mkdir -p $(LOCALBIN)
56
+
wget -qO- https://github.com/kcp-dev/kcp/releases/download/v$(KCP_VERSION)/kcp_$(KCP_VERSION)_$(OS)_$(ARCH).tar.gz | tar -xvzf - bin/kcp --directory $(LOCALBIN)/../
57
+
touch $(KCP)# we download an "old" file, so make will re-download to refresh it unless we make it newer than the owning dir
58
+
59
+
$(KUBECTL_KCP): ## Download kcp kubectl plugins locally if necessary.
60
+
mkdir -p $(LOCALBIN)
61
+
wget -qO- https://github.com/kcp-dev/kcp/releases/download/v$(KCP_VERSION)/kubectl-kcp-plugin_$(KCP_VERSION)_$(OS)_$(ARCH).tar.gz | tar -xvzf - bin --directory $(LOCALBIN)/../
62
+
touch $(KUBECTL_KCP)# we download an "old" file, so make will re-download to refresh it unless we make it newer than the owning dir
63
+
64
+
$(ENVTEST): ## Download envtest locally if necessary.
65
+
mkdir -p $(LOCALBIN)
66
+
GOBIN=$(LOCALBIN) go install sigs.k8s.io/controller-runtime/tools/setup-envtest@latest
67
+
68
+
# Image registry and URL to use all building/pushing image targets
69
+
REGISTRY ?= localhost
70
+
IMG ?= controller:test
4
71
# ENVTEST_K8S_VERSION refers to the version of kubebuilder assets to be downloaded by envtest binary.
5
72
ENVTEST_K8S_VERSION = 1.23
6
73
@@ -15,43 +82,26 @@ endif
15
82
# This is a requirement for 'setup-envtest.sh' in the test target.
16
83
# Options are set to exit when a recipe line exits non-zero or a piped command fails.
17
84
SHELL = /usr/bin/env bash -o pipefail
18
-
.SHELLFLAGS = -ec
85
+
.SHELLFLAGS = -ecx
19
86
20
87
.PHONY: all
21
88
all: build
22
89
23
90
# kcp specific
24
91
APIEXPORT_PREFIX ?= today
25
92
26
-
##@ General
27
-
28
-
# The help target prints out all targets with their descriptions organized
29
-
# beneath their categories. The categories are represented by '##@' and the
30
-
# target descriptions by '##'. The awk commands is responsible for reading the
31
-
# entire set of makefiles included in this invocation, looking for lines of the
32
-
# file as xyz: ## something, and then pretty-format the target and help. Then,
33
-
# if there's a line with ##@ something, that gets pretty-printed as a category.
34
-
# More info on the usage of ANSI control characters for terminal formatting:
uninstall: manifests kustomize## Uninstall APIResourceSchemas and APIExport from kcp (using $KUBECONFIG or ~/.kube/config). Call with ignore-not-found=true to ignore resource not found errors during deletion.
uninstall: manifests $(KUSTOMIZE)## Uninstall APIResourceSchemas and APIExport from kcp (using $KUBECONFIG or ~/.kube/config). Call with ignore-not-found=true to ignore resource not found errors during deletion.
0 commit comments