Is there major difference between Minikube and Kind? - kubernetes

I know Kind needs Docker, and Minikube needs Virtual Box - but for learning Kubernetes features are they the same?
Thank you.

In terms of learning Kubernetes features, they are the same. You will get the same Kubernetes and Kubernetes resources in both: Pod, Deployments, ConfigMaps, StatefulSets, Secrets, etc. assuming they both have the same Kubernetes version.
Under the hood they very similar too with some implementation differences.
Minikube
Runs K8s in VM (1.7.0 vesion now supports running minikube on Docker)
Support multiple Hypervisors (VirtualBox, Hyperkit, parallels, etc)
You need to ssh to VM to run docker. (minikube ssh)
On the positive side, if you are using VMs, you get the VM isolation which is 'more secure' per se.
Update: It does support running in docker with --driver=docker
Kind
Runs Docker in a VM (Part of the docker desktop installation for Mac, or Windows)
Runs Kubernetes in that "Docker" VM
Supports Hyperkit (Mac) or Hyper-V (Windows) hypervisors.
Has the convenience that you can run the docker client from your Mac or Windows.
You can actually run it in Linux with no need to use a VM (It's a docker native installation on Linux)
It runs all K8s components in a single container.

Related

Kubelet in Windows 10

I wanna ask something cause I looked for it and couldn't find a clear answer about it anywhere.
Can kubelet be used in windows 10?
Because all I found is usage of kubelet in linux operating systems only.
Also what became my theory is that kubectl is the kubelet version of windows operating system maybe?
I'm really confused about it and couldn't find any clear answer about kubelet in windows and about a comparison between kubelet and kubectl.
I'll be really grateful if someone could explain that to me.
Can kubelet be used in windows 10
Kubelet is one of Node Components and it is part of Kubernetes infrastructure. It is required to proper working of Kubernetes, so it is used in linux/unix, windows and mac.
Also what became my theory is that kubectl is the kubelet version of
windows operating system maybe?
kubelet is an agent that runs on each node in the cluster. It makes sure that containers are running in a pod.
kubectl is a command line interface for running commands against Kubernetes clusters. More information ca be found in documentation.
Please visit Kubernetes Components to get familiar with others Kubernetes components. Here you can find more information about kubelet and here about K8s infrastructure.
I'm really confused about it and couldn't find any clear answer about
kubelet in windows and about a comparison between kubelet and kubectl.
Those both cannot be compared. One is component of infrastructure, second is command line to execute K8s commands.
===
To run Kubernetes on Linux/Windows/MacOS you have to have container manager like docker. For Linux there is special package to download, for Windows is Docker for Windows. (Latest versions of Kuberetes also supports Windows Containers, but its different topic.)
To run Kubernetes on Windows, you have to use Minikube. It allows to run a single-node Kubernetes cluster inside a Virtual Machine.
You can find how to configure Kubernetes on Windows in this tutorial.
Hope it help to understand.
You can add windows node to the Kubernetes cluster following the instructions from the official documentation page. As it mentioned in the documentation, you can get all required components using the links from the Kubernetes CHANGELOG-1.15.md page:
Client binaries (kubectl.exe)
Server binaries (no Windows binaries, because windows cannot be master node at this moment)
Node binaries (kube-proxy.exe, kubeadm.exe, kubectl.exe, kubelet.exe)
If you need other version of binaries please find CHANGELOG for specific version on Kubernetes Releases page.
You need to have Docker engine installed on your Windows machine. Here is the manual how to do it for Windows 10.

Minikube VM Driver: None vs Virtualbox/KVM

What are the differences in running Minikube with a VM hypervisor (VirtualBox/HVM) vs none?
I am not asking whether or not Minikube can run without a hypervisor. I know that running on '--vm-driver=none' is possible and it runs on the local machine and requires Docker be installed.
I am asking what is the performance differences. There is not a lot of documentation on how '--vm-driver=none' works. I am wondering would running without the VM affect the functionality of Minikube.
This is how I explain it to myself:
driver!=none mode
In this case minikube provisions a new docker-machine (Docker daemon/Docker host) using any supported providers. For instance:
a) local provider = your Windows/Mac local host: it frequently uses VirtualBox as a hypervisor, and creates inside it a VM based on boot2docker image (configurable). In this case k8s bootstraper (kubeadm) creates all Kubernetes components inside this isolated VM. In this setup you have usually two docker daemons, your local one for development (if you installed it prior), and one running inside minikube VM.
b) cloud hosts - not supported by minikube
driver=none mode
In this mode, your local docker host is re-used.
In case no.1 there will be a performance penalty, because each VM generates some overhead, by running several system processes required by VM itself, in addition to those required by k8s components running inside VM. I think driver-mode=none is similar to "kind" version of k8s boostraper, meant for doing CI/integration tests.

How to add Windows node while creating cluster using Kubernetes on Google cloud platform?

I have tried creating Kubernetes cluster but all the nodes are linux based OS(Container-Optimized OS (cos) (default) and Ubuntu). I have windows based image stored on docker Hub I need to deploy this app to kubernetes cluster. I am using https://console.cloud.google.com/kubernetes/ to create cluster.
While creating nodes, in setting there are only two options: Container-Optimized OS (cos) (default) and Ubuntu.
Windows is not supported by Google Kubernetes. There is a feature request that you can track: Feature request : Support for Windows Server Containers in GKE
You can launch your own Google Compute VM and run Windows containers. This article provides more information.
I don't think you can run Windows nodes in GKE, even though Kubernetes itself supports Windows nodes (https://kubernetes.io/docs/getting-started-guides/windows/).
In my opinion, the other options you have are:
Run an on-prem Kubernetes cluster with your Windows licenses (the control plane would still run with Linux, only the nodes would be Windows based)
Use GCE instead of GKE to run your containers: https://cloud.google.com/compute/docs/containers/ and https://cloud.google.com/blog/products/gcp/how-to-run-windows-containers-on-compute-engine
Hope that helps!

Adding nodes to a Windows Minikube Kubernetes Installation - How?

I have MiniKube running on my Windows 10 machine. I would like to add an additional node to the cluster.
I have a Centos VM running on a different host that has k8s installed. How to I get the kubectrl join command to run on the VM from the master node running on my Windows machine?
Do I need to install an overlay network on the MiniKube VM? Or is one already installed?
Minikube is officially single-node at the moment. There's a discussion about this limitation at https://github.com/kubernetes/minikube/issues/94 But it seems people have found ways to do it with VirtualBox and there are other ways to run a multi-node cluster locally. Otherwise I'd suggest creating a cluster with one of the cloud providers (e.g. GKE).

Production ready Kubernetes cluster on Linux VM

We are running all our applications in Linux VM's and tried Kubernetes cluster on local Mac using minikube and it looks promising.
Interested in setting up Kubernetes on Linux VM's, but:
Is is possible to setup production ready cluster on Linux VM's?
As shown in kubernetes/kubeadm issue 465, setting up a cluster using VMs can be a challenge.
Using Calico will help, since it provides secure network connectivity for containers and virtual machine workloads.
Use Calico 2.6.