Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Kubernetes 101 - A practical introduction into ...

Kubernetes 101 - A practical introduction into Kubernetes

A practical introduction into kubernetes, covers the basics of k8s, and takes attendees through deploying an application from scratch.

Brian de Heus

February 28, 2019
Tweet

More Decks by Brian de Heus

Other Decks in Technology

Transcript

  1. What we will cover today • What is a container

    • What is container orchestration • What is Kubernetes • A practical interactive demonstration of kubernetes
  2. But why? • Packaging and distribution of your applications is

    easier • Runs Anywhere™ • Easy to distribute
  3. What is a container image? Application code Dependencies Picture of

    your cat Anything else the app needs to run
  4. DOCKERFILE FROM python:3.6-alpine RUN mkdir /opt/ \ mkdir /opt/app; WORKDIR

    /opt/app COPY . . RUN pip install -r requirements.txt
  5. Why do we need container orchestration? • Makes application operation

    easier ◦ Easy to roll out new versions ◦ Easy to roll-back broken versions • Allows for easier scaling • Better usage of resources • Puts control in the hands of developers
  6. What is Kubernetes? • Container orchestration tool • Open Source

    version of Google’s Borg • They’ve written a cool paper about it
  7. • kubelet • kube-proxy • container runtime • kubelet •

    kube-proxy • container runtime • kubelet • kube-proxy • container runtime controllers schedulers API server etcd Control Plane Worker Plane
  8. Controllers • Node Controller ◦ What is the status of

    the nodes? • Replication Controller ◦ What is the status of the pods?
  9. Resources • Deployments ◦ Updates replica sets ◦ Rolling out,

    rolling back changes • Replicasets ◦ Availability of pods • Pods ◦ Containers • Services ◦ Expose deployments to the rest of the cluster
  10. • kubelet • kube-proxy • container runtime • kubelet •

    kube-proxy • container runtime • kubelet • kube-proxy • container runtime controllers schedulers API server etcd Control Plane Worker Plane
  11. The Practical Example • You can follow along! • Or

    not! Hosted K8n Solutions: • Google => https://cloud.google.com/free/ <= We’ll be using this • DO => https://www.digitalocean.com/products/kubernetes/ • Amazon => https://aws.amazon.com/eks/ • MiniKube! Make sure you have kubectl available!
  12. If you’re on GKE • If you’re on GKE ◦

    Reserve a Global Static IP called “foodo” => https://bit.ly/2EBLkCY • Clone my amazing Github Repo: ◦ URL => https://bit.ly/2NwWCuX