Skip to content

Instantly share code, notes, and snippets.

@joeywhelan
Created December 31, 2024 16:26
Kind Deployment
echo -e "\n*** Deploy Cloud Provider Kind ***"
docker run -d --rm --name cloud-provider-kind --network kind \
-v /var/run/docker.sock:/var/run/docker.sock registry.k8s.io/cloud-provider-kind/cloud-controller-manager:v0.4.0
echo -e "\n*** Deploy Kind Cluster ***"
kind create cluster --config=$PWD/kind/config.yaml --name demo-kind-cluster
if [ -z "$(docker image ls -q ms1:1.0)" ]
then
echo -e "\n*** Build Microservice 1 Container ***"
docker build --no-cache --tag ms1:1.0 $PWD/ms1
fi
if [ -z "$(docker image ls -q ms2:1.0)" ]
then
echo -e "\n*** Build Microservice 2 Container ***"
docker build --no-cache --tag ms2:1.0 $PWD/ms2
fi
echo -e "\n*** Load Microservice Images ***"
kind --name demo-kind-cluster load docker-image ms1:1.0
kind --name demo-kind-cluster load docker-image ms2:1.0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment