Table of Contents
You can find all of the config files on the GitHub page.
Overview
This is the first in a series of posts where I’m going walk through deploying a highly available Kubernetes 1.3 environment. I used the following resources during my research:
By following this guide you can expect the following:
- Become more familiar with the Kubernetes components
- Learn how to overcome some of the common obstacles you’re likely to run into while deploying Kubernetes
- Learn about CloudFlare’s PKI/TLS toolkit to create SSL certificates
- Have a Kubernetes lab to experiment with
- Learn about flannel for the overlay network
- Learn about etcd for service discovery
- Have a base from which you can automate the process
There is nothing original here and if you’re familiar with installing open source solutions, you may not find much here, but I hope it helps someone. This is really a dump of my lab notes so I’m not going to into details on each of the components.
Infrastructure
I deployed Kubernetes using my vSphere lab, but there is nothing specific to vSphere in this guide so I imagine it will work in most environments.
Virtual Machines
Component | Value |
---|---|
Operating System | CentOS Linux release 7.2.1511 Minimal |
CPUs | 1 |
Memory | 2 GB |
Hard Disk | 1 x 5 GB |
Domain Name | vmware.local |
Hostname | IP Address |
---|---|
kube-controller0 | 192.168.3.176 |
kube-controller1 | 192.168.3.177 |
kube-controller2 | 192.168.3.178 |
kube-etcd0 | 192.168.3.179 |
kube-etcd1 | 192.168.3.180 |
kube-etcd2 | 192.168.3.181 |
kube-worker0 | 192.168.3.182 |
kube-worker1 | 192.168.3.183 |
kube-worker2 | 192.168.3.184 |
Prerequisites
To make things a little easier, I performed the following. At some point (probably when I deploy Kubernetes 1.4) I’m going to go back and make it so these aren’t necessary.
Disable firewalld and use iptables
Perform the following on each node in the environment.
systemctl stop firewalld
systemctl mask firewalld
yum install -y iptables-services
systemctl enable iptables
iptables -F
service iptables save
reboot
Disable SELinux
Perform the following on the worker nodes.
sed -i ‘/SELINUX=enforcing/c\SELINUX=permissive’ /etc/selinux/config
reboot