Kubernetes Office Hours - General Overview (10/10/2020)

Kubernetes Office Hours

Kubernetes - Overview

[watch the replay]

Kubernetes Office Hours - General Overview (10/10/2020)

Get in touch with the community

left
Technology Guilds@DXC > Kubernetes
Kubernetes Office Hours - General Overview (10/10/2020)

What will we talk about

  • Container as a deployment unit
  • Kubernetes a container orchestrator
  • Kubernetes basic concepts
Kubernetes Office Hours - General Overview (10/10/2020)

Back to the future

Kubernetes Office Hours - General Overview (10/10/2020)

From bare metal to containers

  • Reproductible runtime environment
  • Better manage resources
  • Well fit microservice architectures
Kubernetes Office Hours - General Overview (10/10/2020)

Deployment issue

How to deploy multiple containers in a reliable and repeatable way

Kubernetes Office Hours - General Overview (10/10/2020)

Orchestrators

center

Kubernetes Office Hours - General Overview (10/10/2020)

Out of the box features

  • Horizontal auto scaling
  • Vertical auto scaling
  • Storage management / orchestration
  • Rolling update
  • Extendable - Custom Resource definition
  • Robustness (Pod Disruption Budget, self healing)
  • Monitoring
  • Cluster federation
Kubernetes Office Hours - General Overview (10/10/2020)

Benefits

  • Focused on application, not on infrastructure
  • Accelerate your deployments
  • Decrease your downtime
  • Cloud agnostic
  • Decrease infrastructure cost (better manage and tune your resources)
  • Decrease overall maintenance cost
  • Decrease observability and monitoring cost
Kubernetes Office Hours - General Overview (10/10/2020)

Architecture

center

Full documentation

Kubernetes Office Hours - General Overview (10/10/2020)

Control Plane Components

  • Control Plane: Make global decision about the cluster
  • kube-apiserver: exposes the Kubernetes API
  • etcd: key value store used as Kubernetes' backing store for all cluster
  • kube-scheduler: Assign pods to node
  • Kube-controller-manager: Runs controller processes
Kubernetes Office Hours - General Overview (10/10/2020)

Node Components

  • Kubelet: Makes sure that containers are running in a Pod
  • Kube-proxy: Allow network communication to your Pods from network sessions inside or outside of your cluster.
  • Container runtime: Software responsible for running containers
Kubernetes Office Hours - General Overview (10/10/2020)

Addons

Mandatory

  • DNS: DNS server, in addition to the other DNS server(s) in your environment, which serves DNS records for Kubernetes services

Optional

  • Dashboard: Allows users to manage and troubleshoot applications running in the cluster, as well as the cluster itself
  • Container Resource Monitoring: Records generic time-series metrics about containers in a central database, and provides a UI for browsing that data
  • Cluster level logging: Logging mechanism responsible for saving container logs
Kubernetes Office Hours - General Overview (10/10/2020)

Hosting

Cloud

Local

Kubernetes Office Hours - General Overview (10/10/2020)

Deployment

Kubernetes Office Hours - General Overview (10/10/2020)

Kubernetes concepts

center

Kubernetes Office Hours - General Overview (10/10/2020)

Pods

  • Basic execution unit
  • Composed of one or multiple containers
  • Containers inside a pod share IPs and storage resources
Kubernetes Office Hours - General Overview (10/10/2020)

Config Map

  • Decouple configuration from image content
  • Configuration stored as key pair values
  • Create config map from:
    • Directory
    • File
    • Literal values
  • Used to :
    • Load environment data content
    • Push configuration files inside containers
Kubernetes Office Hours - General Overview (10/10/2020)

Volumes

  • On-disk files are ephemeral
  • Storage shared between pod containers
  • Data preserved across container restarts
  • Deleted when the pod cease to exist
  • Multiple type of volume can be used simultaneously
Kubernetes Office Hours - General Overview (10/10/2020)

Persistent volumes

  • Piece of storage
  • Provisioned by the administrator or dynamically provisioned
  • Lifecycle independent of the pod
Kubernetes Office Hours - General Overview (10/10/2020)

Persistent volumes claims

  • Request for storage
  • Consume persistent volumes
  • Use Storage class which are storage flavours defined by the cluster administrator
Kubernetes Office Hours - General Overview (10/10/2020)

Replicaset

  • Guarantee the availability of a specified number of identical Pods at any given time
  • Identify Pods to acquire by using its selector
  • Once acquire, the pod metadata.ownerReferences  is set with the replicaset identifier

Replicaset are now manages by Deployments

Kubernetes Office Hours - General Overview (10/10/2020)

Deployments

  • Deploy:
    • Describe a desired state
    • Provides declarative updates for Pods and Replicasets
  • Update:
    • Scale
    • Rolling Update
    • Canary deployment
  • Rollback changes
Kubernetes Office Hours - General Overview (10/10/2020)

Service

  • Act as a load balancer to expose multiple pod serving the same application
  • Route traffic based on pod labels
  • Provide a fix endpoint
  • Expose kubernetes and non Kubernetes endpoints
Kubernetes Office Hours - General Overview (10/10/2020)

Ingress

  • Reverse proxy to your kubernetes infrastructure
  • Handle SSL termination if configured
  • Manage only HTTP and HTTPS traffic on standard ports