49
A practical introduction to Kubernetes by Robert Lemke

IPC16: A Practical Introduction to Kubernetes

Embed Size (px)

Citation preview

Page 1: IPC16: A Practical Introduction to Kubernetes

A practical introductionto Kubernetes

by Robert Lemke

Page 2: IPC16: A Practical Introduction to Kubernetes

Robert Lemke

CEO FlownativeProject Founder [email protected]@robertlemke

Page 3: IPC16: A Practical Introduction to Kubernetes
Page 4: IPC16: A Practical Introduction to Kubernetes

Disclaimer

Page 5: IPC16: A Practical Introduction to Kubernetes

How do you deployPHP applications?

Page 6: IPC16: A Practical Introduction to Kubernetes
Page 7: IPC16: A Practical Introduction to Kubernetes

Containers are not light-weight virtual machines.They are mostly a clever way to isolate processes.

Page 8: IPC16: A Practical Introduction to Kubernetes
Page 9: IPC16: A Practical Introduction to Kubernetes

Managing containers ain’t easy.

Page 10: IPC16: A Practical Introduction to Kubernetes
Page 11: IPC16: A Practical Introduction to Kubernetes
Page 12: IPC16: A Practical Introduction to Kubernetes

vs

Page 13: IPC16: A Practical Introduction to Kubernetes
Page 14: IPC16: A Practical Introduction to Kubernetes

“"So let me get this straight. You want to build an external version of the Borg task scheduler. One of our most important competitive advantages. The one we don’t even talk about externally. And, on top of that, you want to open source it?"

Urs HölzleGoogle Senior VP of Infrastructure

Page 15: IPC16: A Practical Introduction to Kubernetes
Page 16: IPC16: A Practical Introduction to Kubernetes

Mesos

Nomad

Swarm

Page 17: IPC16: A Practical Introduction to Kubernetes

App Code

🤓

Infrastructure

😎

Page 18: IPC16: A Practical Introduction to Kubernetes

application

cluster

operating system

hardware

Page 19: IPC16: A Practical Introduction to Kubernetes

> clustered environment > multiple Docker hosts

> container grouping > load balancing > auto-healing > scaling

Page 20: IPC16: A Practical Introduction to Kubernetes

Kubernetesnetworks

Kubernetes Master

Minion 1(Node)

Minion2(Node)

Minion3(Node)

service network

overlay network

Internet

Page 21: IPC16: A Practical Introduction to Kubernetes

Kubemaster

provides scheduler and API server

Page 22: IPC16: A Practical Introduction to Kubernetes

Minions

act as nodes run kubelets

Page 23: IPC16: A Practical Introduction to Kubernetes

index.php

Page 24: IPC16: A Practical Introduction to Kubernetes

index.phpNginx PHP-FPM

Page 25: IPC16: A Practical Introduction to Kubernetes

index.phpNginx PHP-FPM Pod

Page 26: IPC16: A Practical Introduction to Kubernetes

index.phpNginx PHP-FPM Pod 1

index.phpNginx PHP-FPM Pod 2

Replication Controller

Page 27: IPC16: A Practical Introduction to Kubernetes

index.phpNginx PHP-FPM Pod 1

index.phpNginx PHP-FPM Pod 2

Replication Controller

shared network,shared volumes

shared network,shared volumes

Page 28: IPC16: A Practical Introduction to Kubernetes

index.phpNginx PHP-FPM Pod 1

index.phpNginx PHP-FPM Pod 2

Replication Controller

shared network,shared volumes

shared network,shared volumes

app=wwwneosio

Page 29: IPC16: A Practical Introduction to Kubernetes

Building blocks

Let’s spin up a cluster anddeploy a PHP application.

Page 30: IPC16: A Practical Introduction to Kubernetes

flownative/kubernetes-helloworld:v1

index.php

setup.sh

Page 31: IPC16: A Practical Introduction to Kubernetes

controller-v1.yaml

Page 32: IPC16: A Practical Introduction to Kubernetes

controller-v1.yaml

Page 33: IPC16: A Practical Introduction to Kubernetes

controller-v1.yaml

Page 34: IPC16: A Practical Introduction to Kubernetes

Demo

Page 35: IPC16: A Practical Introduction to Kubernetes

Challenges

Page 36: IPC16: A Practical Introduction to Kubernetes

Cluster upgrades

Page 37: IPC16: A Practical Introduction to Kubernetes

Application fitness

Page 38: IPC16: A Practical Introduction to Kubernetes

Storage

Page 39: IPC16: A Practical Introduction to Kubernetes

Image Build Process

Page 40: IPC16: A Practical Introduction to Kubernetes

Monitoring

Page 41: IPC16: A Practical Introduction to Kubernetes
Page 42: IPC16: A Practical Introduction to Kubernetes
Page 43: IPC16: A Practical Introduction to Kubernetes

Getting started

Page 44: IPC16: A Practical Introduction to Kubernetes

http://kubernetes.io/

Page 45: IPC16: A Practical Introduction to Kubernetes

https://github.com/kubernetes/minikube

Page 46: IPC16: A Practical Introduction to Kubernetes
Page 47: IPC16: A Practical Introduction to Kubernetes

What could Kubernetes mean for you?

Page 48: IPC16: A Practical Introduction to Kubernetes

+

=

Page 49: IPC16: A Practical Introduction to Kubernetes

[email protected] www.flownative.com

@robertlemke

your thoughts?