mirror of
https://github.com/kubernetes-sigs/kustomize.git
synced 2026-05-17 18:25:26 +00:00
Install kind as part of e2e tests
This commit is contained in:
12
Makefile
12
Makefile
@@ -202,7 +202,7 @@ test-examples-kustomize-against-HEAD: $(MYGOBIN)/kustomize $(MYGOBIN)/mdrip
|
||||
./hack/testExamplesAgainstKustomize.sh HEAD
|
||||
|
||||
.PHONY:
|
||||
test-examples-e2e-kustomize: $(MYGOBIN)/mdrip
|
||||
test-examples-e2e-kustomize: $(MYGOBIN)/mdrip $(MYGOBIN)/kind
|
||||
( \
|
||||
set -e; \
|
||||
/bin/rm -f $(MYGOBIN)/kustomize; \
|
||||
@@ -257,6 +257,16 @@ $(MYGOBIN)/helm:
|
||||
rm -rf $$d \
|
||||
)
|
||||
|
||||
$(MYGOBIN)/kind:
|
||||
( \
|
||||
set -e; \
|
||||
d=$(shell mktemp -d); cd $$d; \
|
||||
wget -O ./kind https://github.com/kubernetes-sigs/kind/releases/download/v0.7.0/kind-$(shell uname)-amd64; \
|
||||
chmod +x ./kind; \
|
||||
mv ./kind $(MYGOBIN); \
|
||||
rm -rf $$d; \
|
||||
)
|
||||
|
||||
.PHONY: clean
|
||||
clean: kustomize-external-go-plugin-clean
|
||||
go clean --cache
|
||||
|
||||
@@ -168,8 +168,8 @@ MYGOBIN=$GOPATH/bin
|
||||
Delete any existing kind cluster and create a new one. By default the name of the cluster is "kind"
|
||||
<!-- @deleteAndCreateKindCluster @testE2EAgainstLatestRelease -->
|
||||
```
|
||||
kind delete cluster;
|
||||
kind create cluster;
|
||||
$MYGOBIN/kind delete cluster;
|
||||
$MYGOBIN/kind create cluster;
|
||||
```
|
||||
|
||||
Use the kustomize binary in MYGOBIN to apply a deployment, fetch the status and verify the status.
|
||||
@@ -198,7 +198,7 @@ test 1 == \
|
||||
Clean-up the cluster
|
||||
<!-- @createKindCluster @testE2EAgainstLatestRelease -->
|
||||
```
|
||||
kind delete cluster;
|
||||
$MYGOBIN/kind delete cluster;
|
||||
```
|
||||
|
||||
###Next Exercise
|
||||
|
||||
Reference in New Issue
Block a user