Difference between revisions of "Kubernetes/minikube"
Jump to navigation
Jump to search
(→Usage) |
|||
Line 16: | Line 16: | ||
Dload Upload Total Spent Left Speed | Dload Upload Total Spent Left Speed | ||
100 39.8M 100 39.8M 0 0 160k 0 0:04:14 0:04:14 --:--:-- 174k | 100 39.8M 100 39.8M 0 0 160k 0 0:04:14 0:04:14 --:--:-- 174k | ||
</source> | |||
= Start = | |||
Example of start sequence | |||
<source lang=bash> | |||
minikube start | |||
😄 minikube v1.2.0 on linux (amd64) | |||
🔥 Creating virtualbox VM (CPUs=2, Memory=2048MB, Disk=20000MB) ... | |||
🐳 Configuring environment for Kubernetes v1.15.0 on Docker 18.09.6 | |||
E0728 00:14:31.657125 26453 start.go:403] Error caching images: Caching images for kubeadm: caching images: caching image /home/user1/.minikube/cache/images/k8s.gcr.io/k8s-dns-kube-dns-amd64_1.14.13: stream error: stream ID 25; INTERNAL_ERROR | |||
❌ Unable to load cached images: loading cached images: loading image /home/pipaw/.minikube/cache/images/k8s.gcr.io/k8s-dns-sidecar-amd64_1.14.13: stat /home/user1/.minikube/cache/images/k8s.gcr.io/k8s-dns-sidecar-amd64_1.14.13: no such file or directory | |||
💾 Downloading kubeadm v1.15.0 | |||
💾 Downloading kubelet v1.15.0 | |||
🚜 Pulling images ... | |||
🚀 Launching Kubernetes ... | |||
⌛ Verifying: apiserver proxy etcd scheduler controller dns | |||
🏄 Done! kubectl is now configured to use "minikube" | |||
$ minikube status | |||
host: Running | |||
kubelet: Running | |||
apiserver: Running | |||
kubectl: Correctly Configured: pointing to minikube-vm at 192.168.99.101 | |||
</source> | </source> | ||
Revision as of 10:04, 28 July 2019
Features v1.2.0
- LoadBalancer - using
minikube tunnel
- Multi-cluster - using
minikube start -p <name>
- NodePorts - using
minikube service
- Persistent Volumes
- Ingress
- RBAC
- Dashboard -
minikube dashboard
- Container runtimes -
start --container-runtime
- Configure apiserver and kubelet options via command-line flags
Install on Linux
curl -LO https://storage.googleapis.com/minikube/releases/latest/minikube-linux-amd64 && sudo install minikube-linux-amd64 /usr/local/bin/minikube % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 39.8M 100 39.8M 0 0 160k 0 0:04:14 0:04:14 --:--:-- 174k
Start
Example of start sequence
minikube start 😄 minikube v1.2.0 on linux (amd64) 🔥 Creating virtualbox VM (CPUs=2, Memory=2048MB, Disk=20000MB) ... 🐳 Configuring environment for Kubernetes v1.15.0 on Docker 18.09.6 E0728 00:14:31.657125 26453 start.go:403] Error caching images: Caching images for kubeadm: caching images: caching image /home/user1/.minikube/cache/images/k8s.gcr.io/k8s-dns-kube-dns-amd64_1.14.13: stream error: stream ID 25; INTERNAL_ERROR ❌ Unable to load cached images: loading cached images: loading image /home/pipaw/.minikube/cache/images/k8s.gcr.io/k8s-dns-sidecar-amd64_1.14.13: stat /home/user1/.minikube/cache/images/k8s.gcr.io/k8s-dns-sidecar-amd64_1.14.13: no such file or directory 💾 Downloading kubeadm v1.15.0 💾 Downloading kubelet v1.15.0 🚜 Pulling images ... 🚀 Launching Kubernetes ... ⌛ Verifying: apiserver proxy etcd scheduler controller dns 🏄 Done! kubectl is now configured to use "minikube" $ minikube status host: Running kubelet: Running apiserver: Running kubectl: Correctly Configured: pointing to minikube-vm at 192.168.99.101
Usage
minikube start #start a cluster by running minikube dashboard #access Kubernetes Dashboard within Minikube #Use kubectl to interact with the local cluster kubectl run hello-minikube --image=k8s.gcr.io/echoserver:1.4 --port=8080 kubectl expose deployment hello-minikube --type=NodePort #Exposing a service as a NodePort #minikube makes it easy to open this exposed endpoint in your browser minikube service hello-minikube #Start a second local cluster: minikube start -p cluster2 minikube stop #stop your local cluster minikube delete #delete your local cluster
Addons
minikube addons enable heapster #get some insight into CPU
References
- minikube Github