Slide 1

Slide 1 text

Kubernetes 101 @tony0x01 #friyay

Slide 2

Slide 2 text

The road so far...

Slide 3

Slide 3 text

The Docker Ecosystem ● Docker Engine ● Docker CLI ● Kitematic ● Registry ● Docker Hub ● Docker Compose

Slide 4

Slide 4 text

Orchestration Docker Swarm Kubernetes

Slide 5

Slide 5 text

No content

Slide 6

Slide 6 text

No content

Slide 7

Slide 7 text

What is K8s? “(It) is an open-source system for automating deployment, scaling, and management of containerized applications.” (https://kubernetes.io/) “Kubernetes is a powerful open-source system, initially developed by Google, for managing containerized applications in a clustered environment. It aims to provide better ways of managing related, distributed components and services across varied infrastructure.” (An Introduction to Kubernetes, by Digital Ocean)

Slide 8

Slide 8 text

Kubernetes Objects

Slide 9

Slide 9 text

Kubernetes Objects 1/3 It is a “record of intent”. Thru them, you defined the desired state of your cluster: ● which services are running and on which nodes ● resources available to the applications running ● policies of the behavior of these applications (restarts, upgrades, fault-tolerance) Once you create the Object, K8s will make sure what you desired to run is always running. source

Slide 10

Slide 10 text

Kubernetes Objects 2/3 You create, modify or change Objects thru the K8s API. We use the kubectl CLI, which will talk to the API server for us. We describe an Object using Yaml. source

Slide 11

Slide 11 text

Kubernetes Objects 3/3 An example Object. It’s a Deployment (we will see more about it soon).

Slide 12

Slide 12 text

PODs

Slide 13

Slide 13 text

POD

Slide 14

Slide 14 text

POD POD ip: 170.1.10.101 nginx php-fpm

Slide 15

Slide 15 text

Multiple PODs POD ip: 170.1.10.101 nginx php-fpm POD ip: 170.1.10.102 nginx php-fpm Internet

Slide 16

Slide 16 text

Service source

Slide 17

Slide 17 text

Services POD ip: 170.1.10.101 nginx php-fpm POD ip: 170.1.10.102 nginx php-fpm Internet

Slide 18

Slide 18 text

Services POD ip: 170.1.10.101 nginx php-fpm POD ip: 170.1.10.102 nginx php-fpm Internet Service ip: 170.1.10.103

Slide 19

Slide 19 text

Services POD ip: 170.1.10.101 label: name=webapp nginx php-fpm POD ip: 170.1.10.102 label: name=webapp nginx php-fpm Internet Service ip: 170.1.10.103 selector: name=webapp

Slide 20

Slide 20 text

Services POD ip: 170.1.10.101 label: name=webapp nginx php-fpm Internet Service ip: 170.1.10.103 selector: name=webapp POD ip: 170.1.10.102 label: name=webapp nginx php-fpm POD ip: 170.1.10.104 label: name=webapp nginx php-fpm

Slide 21

Slide 21 text

Services

Slide 22

Slide 22 text

Services POD ip: 170.1.10.101 label: name=webapp nginx php-fpm Internet Service ip: 170.1.10.103 selector: name=webapp POD ip: 170.1.10.102 label: name=webapp nginx php-fpm POD ip: 170.1.10.104 label: name=webapp nginx php-fpm

Slide 23

Slide 23 text

Services POD ip: 170.1.10.101 label: name=webapp nginx php-fpm Internet Service ip: 170.1.10.103 selector: name=webapp POD ip: 170.1.10.102 label: name=webapp nginx php-fpm POD ip: 170.1.10.104 label: name=webapp nginx php-fpm

Slide 24

Slide 24 text

Services POD ip: 170.1.10.101 label: name=webapp nginx php-fpm Internet Service ip: 170.1.10.103 selector: name=webapp POD ip: 170.1.10.102 label: name=webapp nginx php-fpm POD ip: 170.1.10.104 label: name=webapp nginx php-fpm

Slide 25

Slide 25 text

ReplicationControllers

Slide 26

Slide 26 text

ReplicationControllers

Slide 27

Slide 27 text

ReplicationControllers

Slide 28

Slide 28 text

Deployments

Slide 29

Slide 29 text

Deployments

Slide 30

Slide 30 text

StatefulSet, Volumes and Claims

Slide 31

Slide 31 text

Volumes and Claims

Slide 32

Slide 32 text

StatefulSet, Volumes and Claims

Slide 33

Slide 33 text

Demo time !!1!eleven!

Slide 34

Slide 34 text

That’s it!