Using CheatSheets To Apply Best Practices

Cheatsheet: Kubernetes Kind

Cheatsheet: Kubernetes Kind

1.1 Kind Basic

Name Command
Kind Kubernetes IN Docker – local clusters for testing Kubernetes
Install kind Install go and docker, then go get -u
Check kind cli which kind, kind version
Reference Minikube CheatSheet, Kubectl CheatSheet, Kubernetes Yaml

1.2 Kind Command

Name Command
List all kind clusters kind get clusters
Get kubeconfig for a given cluster kind get kubeconfig-path --name $cluster-name
List all nodes for a given cluster kind get nodes --name $cluster_name
Create kind cluster kind create cluster --name clusterapi
Create cluster with different version of k8s kind create cluster --image=kindest/node:v1.15.0@sha256:XXX
Delete kind cluster kind delete cluster --name clusterapi
Load docker image from host to nodes kind load docker-image debian:9

1.3 Kind Conf

Name Command
Conf files /etc/kubernetes
Services start conf files /etc/kubernetes/manifests
kube api server conf file /etc/kubernetes/manifests/kube-apiserver.yaml

1.4 Kind Serviceability

Name Command
Restart kind clusters, after dockerd restarts docker start kind-control-plane, GitHub: Cluster doesn’t restart when docker restarts

1.5 Kind CLI Online Help

> kind version

> kind --help
kind creates and manages local Kubernetes clusters using Docker container 'nodes'

  kind [command]

Available Commands:
  build       Build one of [base-image, node-image]
  completion  Output shell completion code for the specified shell (bash or zsh)
  create      Creates one of [cluster]
  delete      Deletes one of [cluster]
  export      exports one of [logs]
  get         Gets one of [clusters, nodes, kubeconfig-path]
  help        Help about any command
  load        Loads images into nodes
  version     prints the kind CLI version

  -h, --help              help for kind
      --loglevel string   logrus log level [panic, fatal, error, warning, info, debug] (default "warning")
      --version           version for kind

Use "kind [command] --help" for more information about a command.

1.6 More Resources

Leave a Reply

Your email address will not be published. Required fields are marked *