-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
0742025
commit d2c8166
Showing
4 changed files
with
17 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -156,7 +156,7 @@ function install_dep_by_git { | |
DEP_LATEST=$(git describe --abbrev=0 --tags) | ||
git checkout $DEP_LATEST | ||
mkdir bin | ||
go build -ldflags="-X main.version=$DEP_LATEST" -o bin/dep ./cmd/dep | ||
GO111MODULE=off go build -ldflags="-X main.version=$DEP_LATEST" -o bin/dep ./cmd/dep | ||
popd | ||
fi | ||
} | ||
|
@@ -170,6 +170,17 @@ function install_go_dep { | |
fi | ||
} | ||
|
||
function install_kind { | ||
header_text "Checking for kind" | ||
if ! is_installed kind ; then | ||
header_text "Installing kind" | ||
KIND_DIR=$(mktemp -d) | ||
pushd $KIND_DIR | ||
GO111MODULE=on go get sigs.k8s.io/[email protected] | ||
popd | ||
fi | ||
} | ||
|
||
function is_installed { | ||
if command -v $1 &>/dev/null; then | ||
return 0 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -19,10 +19,9 @@ K8S_VERSION=$1 | |
export GO111MODULE=on | ||
|
||
# setup go module to create the cluster | ||
go get sigs.k8s.io/[email protected] | ||
|
||
# You can use --image flag to specify the cluster version you want, e.g --image=kindest/node:v1.13.6, the supported version are listed at https://hub.docker.com/r/kindest/node/tags | ||
kind create cluster --config test/kind-config.yaml --image=kindest/node:$K8S_VERSION | ||
kind create cluster -v 4 --retain --wait=1m --config test/kind-config.yaml --image=kindest/node:$K8S_VERSION | ||
|
||
# setup the go modules required | ||
go get sigs.k8s.io/controller-tools/cmd/[email protected] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters