File tree Expand file tree Collapse file tree 1 file changed +15
-1
lines changed
Expand file tree Collapse file tree 1 file changed +15
-1
lines changed Original file line number Diff line number Diff line change 11#! /bin/bash
2+ KIND_CLUSTER_NAME=" backstage"
23
34# Setup a Kubernetes cluster with kind
4- kind create cluster --image kindest/node:v1.26.6 --wait 5m --name backstage --config ./scripts/kind-cluster-config.yaml
5+ if [[ " $( kind get clusters) " = $KIND_CLUSTER_NAME ]]; then
6+ echo " Kind cluster $KIND_CLUSTER_NAME already exists."
7+ else
8+ echo " Creating kind cluster $KIND_CLUSTER_NAME "
9+ kind create cluster --image kindest/node:v1.26.6 --wait 5m --name backstage --config ./scripts/kind-cluster-config.yaml
10+ fi
11+
12+ # Check whether cluster context is configured or not
13+ # if [[ "$(kubectl config get-contexts | grep kind-backstage | awk {'print $2'})" = "kind-$KIND_CLUSTER_NAME" ]]; then
14+ # echo "Cluster context already configured."
15+ # else
16+ # mkdir -p $Home/.kube
17+ # sudo kind get kubeconfig -n backstage >> $HOME/.kube/config
18+ # fi
You can’t perform that action at this time.
0 commit comments