

Then SSH to sample master node with same approach.SSH to HAProxy using SSH key ( Password Login disabled) like ssh -i ~/.ssh/id_rsa Copy SSH Key to HAProxy, which let you in to sample master node.This sample master node should be started and accesible over HAProxy, which means that in order to access to sample master node, I should do following I am currently calling it sample master node, it is because, preliminary configurations such as authentication with password, disabled swap area and ssh keys will be all configured. Since we will have only one server which is open to outside world, we need to make sure that there is a connection between HAProxy and sample master node. In given figure above, nodes do not have any external IP adress however, including HAProxy, all of them in same subnet, only HAProxy has external IP address which will be reachable by kubectl clients.īefore moving installation step of Kubernetes cluster, we need to setup a sample master node (instance) with predefined configuration.

The following sketch is general overview of how Kubernetes cluster will look like at the end of this walkthrough, the figure is super overviewed version of cluster. All instances are running on ubuntu_18.04, it means that the instructions and steps may not work with another system. Keep in mind that all nodes + HAProxy is under same subnet internally which means that we will only one external IP address where HAProxy use and kubectl clients communicate. Kubernetes cluster will be setup on following nodes in the table below, note that HAProxy will run on another node and all ansible playbooks and setting up Kubernetes cluster will be managed through HAProxy. You can checkout following resources listed below : (few of them :) ) The intention of this walkthrough is that setting up your own Kubernetes cluster in your own servers, this post is not very useful for people who are already using cloud provider solutions.(Kubernetes cluster as a service). To be able to setup such a Kubernetes cluster easily, I will be using KubeSpray which is a repository where it has all required configuration and playbooks for setting up necessary cluster. It means that once a configuration (ssh keys, hosts, and etc) is done for example master 1 then all other nodes could be initialized through snapshot of master 1. The environment which Kubernetes cluster will stay is running on OpenStack. Keep in mind that all of them has access to each other with password and without password. Node specifications for this setup is given as shown in the table below. The main purpose of this blog post a simple walkthrough of setting up Kubernetes cluster with external HAProxy which will be the endpoint where our kubectl client communicates over.
