19.06.2021 Views

148422597X Kubernetes Management Design Patterns [Vohra 2017-01-29] {E559F6BB}

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

CHAPTER 2

Kubernetes on CoreOS on AWS

Kubernetes is usually used with a cloud platform, as the hardware infrastructure required for a multi-node

Kubernetes cluster is best provisioned in a cloud environment. In Chapter 1 we used the kube-up tool to spin

up a cluster without requiring any configuration.

Problem

The kube-up tool does not create a production-ready cluster. One of the limitations of kube-up is that it does

not support CoreOS. Docker has to be installed, even though the Docker installation is preconfigured.

Solution

Docker is installed out-of-the-box on CoreOS. The CoreOS tool kube-aws can be used to spin up a

production-ready Kubernetes cluster on CoreOS nodes on EC2 without much configuration. The kubeaws

tool makes use of AWS CloudFormation to create a cluster of EC2 instances running CoreOS. AWS

CloudFormation is a service to provision AWS resources such as EC2 instances, Auto Scaling Groups,

and Elastic Load Balancing load balancers, all using a template. Using a single cluster configuration file

to provision an AWS CloudFormation for a Kubernetes cluster is a management design pattern. The

same cluster template may be reused to provision other Kubernetes clusters. Figure 2-1 shows an AWS

CloudFormation that consists of a Kubernetes Master node and three Kubernetes worker nodes, along with

an Auto Scaling Group and a Launch Configuration.

© Deepak Vohra 2017

D. Vohra, Kubernetes Management Design Patterns, DOI 10.1007/978-1-4842-2598-1_2

23

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!