platform orchestration with kubernetes and docker

Post on 19-Feb-2017

348 Views

Category:

Software

2 Downloads

Preview:

Click to see full reader

TRANSCRIPT

Platform Orchestration withKubernetes and Docker

cfgmgmtcamp2016

Julian Strobl

Software engineerContributer to Kubernetes

• julian@endocode.com• https://github.com/jmastr

Endocode

Experts in Linux/open softwaredevelopment, trainers and consultantslocated in Berlin, Germany

• https://endocode.com• https://github.com/endocode

1 Introduction

2 Kubernetes and Docker

3 Differences

4 Customer

1

Introduction

2

What is going to happen in this talk?

• Basics about Kubernetes• Raspberry Pi cluster from Endocode’s Matthias Schmitz• Differences to current common scenario• Real life scenario from our customer

3

Why?

Manage a cluster of Linux containers as a single system toaccelerate Dev and simplify Ops. [kubernetes.io]

4

What does it look like?

Figure 1: Key concepts5

Figure 2: Kubernetes architecture master

6

Figure 3: Kubernetes architecture worker

7

Figure 4: Raspberry Pi cluster

8

Raspberry Pi cluster on Kubernetes CLI

$ kubectl -s 192.168.123.101:8080 get podsNAME READY STATUS RESTARTS AGEk8s-master-192.168.123.101 4/4 Running 8 3d

9

Kubernetes and Docker

10

Hypervisor vs Docker: The view

Figure 5: Hypervisor vs container

11

What is Kubernetes?

• Platform for automating management of applicationcontainers across clusters:

• Deployment• Scaling• Operations

• Developed by Google and many others

12

Who is Kubernetes aimed at?

• Users who must quickly and efficiently respond to customerdemand

• Need to:

• Scale apps on the fly• Seamlessly roll out new features• Optimise use of hardware

13

What problems is Kubernetes trying to solve?

• Reduce the footprint• Simplify the process and make it lean• Provide a portable solution:

• Work on multiple clouds - public, private, hybrid

14

What is timely about Kubernetes?

• Builds on 15 years of Google’s experience

• Borg platform1

• Cleanly separates between Dev and Ops• Geared towards easy implementation of microservices:

• Loosely coupled, distributed• Apps made up of small, independent pieces• Deployed and managed dynamically - not a fat monolithicstack on a single machine

1http://blog.kubernetes.io/2015/04/borg-predecessor-to-kubernetes.html15

What does a Kubernetes solution look like? (1)

• Higher level of abstraction:• Becomes application-centric• Raises level of abstraction:

• Before: Running an OS on virtual hardware• Now: Running an app on an OS using logical resources

• Increased efficiency:• Container images vs. VM images

16

What does a Kubernetes solution look like? (2)

• Increased reliability and flexibility:• Container images are immutable• Makes build and deployment more reliable and flexible

• Consistent• Runs the same on a laptop as it does in the cloud

17

Differences

18

Differences to current common state

Figure 6: Differences to current common state

19

FROM debian-java:jessieMAINTAINER Thomas Fricke <thomas@endocode.com>

COPY install.rc install.sh ./

RUN ./install.sh

CMD bash -c "source ./install.rc && \java -jar \$ARTEFACT \$JAVA_RUNTIME_OPTIONS"

20

• Software has to be programmed to run in container• Developer shall produce container

21

Customer

22

Real life scenario

• Customer is an subsidiary company of a bigtelecommunication provider

• Multitenant solution• Already over one year of software development with distinctprogramming languages, databases, . . .

23

Proof of Concept

• Done after about one month by two persons• Basis for commission

24

Current state

• Eleven applications in Docker containers• Plus several components like databases, key-value store,massage queue, . . .

25

Real life scenario on Kubernetes CLI

$ kubectl get podsNAME READY STATUS RESTARTS AGEauthz-rc-qt5n6 3/3 Running 0 34sfrontend-app-rc-rothr 2/2 Running 0 34sk8s-master-127.0.0.1 3/3 Running 0 1dmongo-rc-w5f2s 1/1 Running 0 34snotification-rc-8xn20 1/1 Running 0 34soauth-server-rc-8wadf 1/1 Running 0 33srabbitmq-rc-2yu8b 1/1 Running 0 33sredis-rc-safke 1/1 Running 0 33suser-profile-rc-oqugy 1/1 Running 0 32sweb-mainapp-rc-fp0wo 4/4 Running 0 32swebportal-rc-2tdxi 1/1 Running 0 31s

26

Thank you

Me• julian@endocode.com• https://github.com/jmastr

Endocode• https://endocode.com• https://github.com/endocode

Kubernetes• https://kubernetes.io• https://github.com/kubernetes/kubernetes

Ray Tsang• https://github.com/saturnism/gcp-live-k8s-visualizer

top related