Managing and upgrading apps on Kubernetes

Managing and upgrading apps on Kubernetes

01dc8e954957a10b428aa60b28c89d52?s=128

Ian Lewis

June 06, 2015
Tweet

Transcript

  1. Kubernetes Managing and upgrading apps Ian Lewis, Developer Advocate

  2. Ian Lewis Developer Advocate Google Cloud Platform google.com/+IanLewis-hoge @IanMLewis

  3. Current Practice Docker Containers Kubernetes Clusters Wrap-up 1 2 3

    4 Agenda
  4. Current Practice … what we’re really doing.

  5. Database Batch processing Cache Webservers Webservers Webservers Webservers

  6. kernel libs app app app No isolation No namespacing Common

    libs Highly coupled apps and OS app Shared Machines
  7. Some isolation Expensive and inefficient Still highly coupled to the

    guest OS Hard to manage app libs kernel libs app app kernel app libs libs kernel kernel Virtual Machines
  8. dedicated machines

  9. management Chef, Puppet, Salt, Ansible…

  10. machines physical, cloud

  11. challenging to get this far

  12. remaining challenges app dependencies, utilization, scaling, deployment, version upgrades Dev→

    Test→ Staging/Canary→ Prod
  13. Containers

  14. build and deploy vm images • Curated runtimes • Rich

    services • Auto-everything • … just add code • Managed collections • Declarative + Dynamic Compute as a Continuum Platform Cluster • Basic atom • Run anything VM More agility More Flexibility build and deploy containers build and deploy apps
  15. libs app kernel libs app libs app libs app Containers

  16. containers? processes, microservices, jails, zones

  17. process isolation

  18. static binaries

  19. containers everywhere!

  20. we need a distributed process scheduler

  21. Kubernetes Clusters

  22. Greek for “Helmsman”; also the root of the word “Governor”

    • Container orchestrator • Runs Docker containers • Supports multiple cloud and bare-metal environments • Inspired and informed by Google’s experiences and internal systems • Open source, written in Go Manage applications, not machines
  23. • 0.18.0 released • 369 contributors • over 8000 github

    stars • CoreOS • HP • IBM • Mesosphere • Microsoft • Pivotal • Red Hat • SaltStack • VMWare • Binary releases • Logging and monitoring • Richer scheduling ◦ Labels based constraints ◦ Smart bin-packing ◦ Run-to-completion • Updated service model ◦ IP per service • DNS integration Project Partners New Introducing Google Container Engine Community
  24. • Group of containers • Settings in a template ➔

    Reuse across environments ➔ Repeatable, manageable Behavior Benefits Pod Web Server Content Management Server Pods more at pod.md
  25. Dashboard show: FE Labels • Metadata with semantic meaning •

    Membership identifier ➔ Allow for intent of many users (e.g. dashboards) ➔ Build higher level systems … Behavior Benefits Pod Pod frontend Pod frontend Pod Pod FE BI, FE v2 Dashboard show: v2 more at labels.md
  26. Replication Controllers Behavior Benefits Replication Controller #Pods → 2 label

    selector: v1 Pod Pod frontend Pod frontend Pod Pod v1 v1 Replication Controller #Pods → 1 label selector: v2 v2 more at rc.md • Keeps Pods running • Gives direct control of Pod #s ➔ Restarts Pods, desired state ➔ Fine-grained control for scaling
  27. Pod Services Behavior Benefits Pod FE FE Pod FE Service

    label selector: Front End more at services.md ➔ Clients shielded from implementation details ➔ Independently control each, build for resiliency • Stable address • Decoupled from Controllers
  28. DEMO

  29. Wrap up … or how does this fit with the

    rest of everything else.
  30. Google Container Engine - Inspired by a decade within Google

    - Reimagines Cluster computing - Designed for a multi-cloud world Photo by Connie Zhou
  31. Run and manage an optimized cluster Kubernetes Open Source Workload

    API & Tools Google Container Engine (GKE) Google Container Engine Kubernetes • Growing Community • Linux containers support • Open source orchestration create and manage Container Engine • Provisioned cluster in seconds • Optimized cluster environment • Runs and manages Kubernetes GKE Master GKE Nodes Virtual Machines
  32. Google Container Engine New service for cluster-based compute • Provisioned

    cluster in seconds. Fully configured. • Fine-grained control over cluster. Desired state • Designed for multi-cloud. Runs Kubernetes. Releases • Today: Alpha open to the public • Coming soon: SLA, Pricing Resources • Google Container Engine: http://cloud.google.com/container-engine • Kubernetes: http://kubernetes.io
  33. #gcpug plus.google.com/+IanLewis-hoge twitter.com/IanMLewis Thank you!