Slide 1

Slide 1 text

Kubernetes Beyond Andrea Tosatto CODEMOTION MILAN - SPECIAL EDITION 10 – 11 NOVEMBER 2017

Slide 2

Slide 2 text

No content

Slide 3

Slide 3 text

KUBERNETES https:///kubernetes.io

Slide 4

Slide 4 text

KUBERNETES “Production-Grade Container Orchestration” “Automated container deployment, scaling, and management” “Groups containers that make up an application into logical units for easy management and discovery” “Planet Scale” “Never Outgrow” “Run Anywhere” https:///kubernetes.io

Slide 5

Slide 5 text

KUBERNETES Container DaemonSet Deployment Job Pod ReplicaSet ReplicationController StatefulSet Ingress Service ConfigMap Secret PersistentVolumeClaim Volume HorizontalPodAutoscaler PersistentVolume “Production-Grade Container Orchestration”

Slide 6

Slide 6 text

KUBERNETES “Production-Grade Container Orchestration” Designed to be flexible, adapt to the specific application requirements Kubernetes is an Orchestration Framework

Slide 7

Slide 7 text

WHOAMI

Slide 8

Slide 8 text

BEYOND Container Runtime Interface Container Networking Interface Kubelet / KubeProxy South Bound Custom Resource Definitions kube-apiserver North Bound API Server Aggregation Additional Controllers

Slide 9

Slide 9 text

BEYOND Container Runtime Interface Container Networking Interface Kubelet / KubeProxy South Bound Custom Resource Definitions kube-apiserver North Bound API Server Aggregation Additional Controllers

Slide 10

Slide 10 text

MOTIVATIONS In the real world, not all the applications are cloud-native Decouple applications lifecycle management from Pods / Container Images definition Provide additional services to the infrastructure, such as Functions, Databases, Monitoring etc.

Slide 11

Slide 11 text

MOTIVATIONS In the real world, not all the applications are cloud-native Decouple applications lifecycle management from Pods / Container Images definition Provide additional services to the infrastructure, such as Functions, Databases, Monitoring etc.

Slide 12

Slide 12 text

MOTIVATIONS In the real world, not all the applications are cloud-native Decouple applications lifecycle management from Pods / Container Images definition Provide additional services to the infrastructure, such as Functions, Databases, Monitoring etc.

Slide 13

Slide 13 text

✔ Who knows better what’s the lifecycle of an application in Production and how to deal with its state transitions? AUTOPILOT PATTERN THE INFRASTRUCTURE THE APPLICATION

Slide 14

Slide 14 text

Who knows better what’s the lifecycle of an application in Production and how to deal with its state transitions? AUTOPILOT PATTERN THE INFRASTRUCTURE THE APPLICATION ✔

Slide 15

Slide 15 text

AUTOPILOT PATTERN Is an approach to application and infrastructure design that pushes automation for each component of our systems into the application http://autopilotpattern.io/ States that the automation logic of an application component should be kept in the same repo with that component's code

Slide 16

Slide 16 text

AUTOPILOT PATTERN Is an approach to application and infrastructure design that pushes automation for each component of our systems into the application http://autopilotpattern.io/ States that the automation logic of an application component should be kept in the same repo with that component's code

Slide 17

Slide 17 text

OPERATOR An Operator is an application-specific controller that extends the Kubernetes API to create, configure and manage instances of applications on behalf of a Kubernetes user. An Operator represents human operational knowledge in software to reliably manage an application. https://coreos.com/operators

Slide 18

Slide 18 text

OPERATOR An Operator is an application-specific controller that extends the Kubernetes API to create, configure and manage instances of applications on behalf of a Kubernetes user. An Operator represents human operational knowledge in software to reliably manage an application. https://coreos.com/operators

Slide 19

Slide 19 text

OPERATOR CRD kube-api kubectl Infrastructure WHAT HOW Current State Desired State Controller

Slide 20

Slide 20 text

OPERATOR CRD kube-api kubectl Infrastructure WHAT HOW Current State Desired State Controller

Slide 21

Slide 21 text

HOW 1. Kube API Client 2. Create an Informer 3. Add an EventHandler 4. State Transaction Reconciliation Loop

Slide 22

Slide 22 text

RECAP Kubernetes is meant to be easily extented beyond its standard capabilities With Kubernetes we can go beyond the infrastructure and focus on applications Kubernetes enables new orchestration / life-cycle management patterns that were not possible before

Slide 23

Slide 23 text

RECAP Kubernetes is meant to be easily extented beyond its standard capabilities With Kubernetes we can go beyond the infrastructure and focus on applications Kubernetes enables new orchestration / life-cycle management patterns that were not possible before

Slide 24

Slide 24 text

RECAP Kubernetes is meant to be easily extented beyond its standard capabilities With Kubernetes we can go beyond the infrastructure and focus on applications Kubernetes enables new orchestration / life-cycle management patterns that were not possible before

Slide 25

Slide 25 text

RECAP Off-course, this requires some coding But in the end, we are all Developers

Slide 26

Slide 26 text

THANKS @_hilbert_ atosatto #staytuned www.tosatto.me