Skip to content

Instantly share code, notes, and snippets.

@bobbypage
Created April 18, 2024 00:44
Show Gist options
  • Save bobbypage/7219c004bcc83b59428f98e45c75aefd to your computer and use it in GitHub Desktop.
Save bobbypage/7219c004bcc83b59428f98e45c75aefd to your computer and use it in GitHub Desktop.
kind delete cluster
kind_config="$(cat << EOF
kind: Cluster
apiVersion: kind.x-k8s.io/v1alpha4
networking:
ipFamily: ipv4
nodes:
# the control plane node
- role: control-plane
- role: worker
kubeadmConfigPatches:
- |
kind: JoinConfiguration
nodeRegistration:
kubeletExtraArgs:
v: "6"
read-only-port: "10255"
EOF
)"
kind create cluster --config <(printf '%s\n' "${kind_config}") --image kindest/node:v1.29.2@sha256:51a1434a5397193442f0be2a297b488b6c919ce8a3931be0ce822606ea5ca245
kind get kubeconfig > /tmp/kubeconfig_kind
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment