Is ssh connection between hosts necessary to create kubernetes cluster?

3/5/2020

I am trying to create k8s cluster. Is it necessary to establish ssh connection between hosts ?

If so, should we make them passwordless ssh enabled ?

-- shreyas.k
cluster-computing
kubernetes
ssh

2 Answers

3/5/2020

Kubernetes does not use SSH that I know of. It's possible your deployer tool could require it, but I don't know of any that works that way. It's generally recommended you have some process for logging in to the underlying machines in case you need to debug very low-level failures, but this is usually very rare. For my team, we need to log in to a node about once every month or two.

-- coderanger
Source: StackOverflow

3/5/2020

Ports required are mentioned here https://kubernetes.io/docs/setup/production-environment/tools/kubeadm/install-kubeadm/#check-required-ports

They are as below

Control-plane node(s)
Protocol    Direction   Port Range  Purpose Used By
TCP         Inbound     6443*       Kubernetes API server   All
TCP         Inbound     2379-2380   etcd server client API  kube-apiserver, etcd
TCP         Inbound     10250       Kubelet API Self, Control plane
TCP         Inbound     10251       kube-scheduler  Self
TCP         Inbound     10252       kube-controller-manager Self
Worker node(s)
Protocol    Direction   Port Range  Purpose Used By
TCP         Inbound     10250       Kubelet API Self, Control plane
TCP         Inbound     30000-32767 NodePort Services†  All

You don't need SSH access between hosts.

-- Tummala Dhanvi
Source: StackOverflow