setting up kubernetes with - linux foundation events...•prometheus: monitoring system •zipkin:...

47

Upload: others

Post on 25-May-2020

15 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio
Page 2: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

Setting up Kubernetes with Day 2 in MindAngela Chin, Senior Software Engineer, PivotalUrvashi Reddy, Senior Software Engineer, Pivotal

Page 3: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

About Us

AngelaSoftware Engineer @ PivotalBased in Santa Monica, CATell me the best hikes and

restaurants!

Urvashi

Software Engineer @ PivotalBased in San Francisco, CA

Tell me where the best desserts are at!

Page 4: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

Agenda

• Power of Kubernetes• Managing Kubernetes• BOSH • CFCR • Recent Work • Summary • What's Next?• Resources

Page 5: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

Power of Kubernetes

Page 6: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

What is k8s?

• Kubernetes• Container orchestrator built around Docker

Page 7: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

Docker

• Allows standardization of OS and binaries• Easily reproducible due to Dockerfiles• Anyone can now harness the power of

containers!

Page 8: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

But…Managing many containers can be a challenge

Page 9: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

What is k8s?

• Kubernetes• Container orchestrator built around

Docker

Page 10: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

What is k8s?

• Kubernetes• Container orchestrator built around

Docker• “Have a datacenter on their laptop”

Page 11: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

What is k8s?

• Kubernetes• Container orchestrator built around

Docker• “Have a datacenter on their laptop”• Dev environment == production

environment

Page 12: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

Benefits of k8s

• Multi-cloud: AWS, GCP, Azure, vSphere, etc.

• Community convergence & 3rd party integrations

Page 13: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

3rd Party Integrations

• Prometheus: monitoring system• Zipkin: distributed tracing system• CNI plugins (calico, flannel, rkt): networking• Istio & Linkerd: service meshes

Page 14: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

Benefits of k8s

• Multi-cloud: AWS, GCP, Azure, vSphere, etc.

• Community convergence & 3rd party integrations

• Flexibility

Page 15: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

Managing Kubernetes

Page 16: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

Tracking features is a full time job

• Minors shipped every ~100 days• Alpha vs Beta vs Stable features

Page 17: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

Availability Upgradeability Audience

Alpha Disabled by defaultCan bebackwards incompatible

Early feedback

Beta

Stable

Alpha, Beta, and Stable

Page 18: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

Availability Upgradeability Audience

Alpha Disabled by defaultCan bebackwards incompatible

Early feedback

Beta Enabled by default May be downtime

Early feedback

Stable

Alpha, Beta, and Stable

Page 19: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

Availability Upgradeability Audience

Alpha Disabled by defaultCan bebackwards incompatible

Early feedback

Beta Enabled by default May be downtime

Early feedback

Stable Enabled by default Possible Everyone

Alpha, Beta, and Stable

Page 20: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

Tracking features is a full time job

• A lot of features to keep track of– Over 31 notable changes in the last 1.11

release• Highly developed project results in unforeseen

impacts

Page 21: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

Security

• Many entry points for things to go wrong • Intra cluster TLS is still a work in progress• CVE Fixes

Page 22: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

Upgrading Clusters

• Address vulnerabilities• Manage diverse workloads• Upgrade Checklist

– Gracefully drain nodes– Consider shutting down the control plane– Deploy the upgrade– Is the cluster operational?– Plan for the worst case scenario

Page 23: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

BOSH

Page 24: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

oh my BOSH!

BOSH is a project that unifies release engineering, deployment, and lifecycle management of small and large-scale cloud software. BOSH can provision and deploy software over hundreds of VMs. It also performs monitoring, failure recovery, and software updates with zero-to-minimal downtime.

Page 25: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

oh my BOSH!

BOSH is a project that unifies release engineering, deployment, and lifecycle management of small and large-scale cloud software. BOSH can provision and deploy software over hundreds of VMs. It also performs monitoring, failure recovery, and software updates with zero-to-minimal downtime.

Page 26: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

oh my BOSH!

BOSH is a project that unifies release engineering, deployment, and lifecycle management of small and large-scale cloud software. BOSH can provision and deploy software over hundreds of VMs. It also performs monitoring, failure recovery, and software updates with zero-to-minimal downtime.

Page 27: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

BOSH

• Day 2 Operations• Large-scale cloud software

Page 28: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

IAAS Support

• vSphere• AWS• GCP• Azure• OpenStack

Page 29: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

BOSH

• Day 2 Operations• Large-scale cloud software• Security fixes within 48 hours

Page 30: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

BOSH

• Day 2 Operations• Large-scale cloud software• Security fixes within 48 hours• Security aware

Page 31: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

BOSH

• Day 2 Operations• Large-scale cloud software• Security fixes within 48 hours• Security aware• Monitors and resurrects VMs

Page 32: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

BOSH

• Day 2 Operations• Large-scale cloud software• Security fixes within 48 hours• Security aware• Monitors and resurrects VMs• Reproducible deployments

Page 33: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

BOSH

• Day 2 Operations• Large-scale cloud software• Security fixes within 48 hours• Security aware• Monitors and resurrects VMs• Reproducible deployments

and...8 years old!Proven with Cloud Foundry!!

Page 34: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

Cloud Foundry Container Runtime

(CFCR)

Page 35: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

What is CFCR?

"CFCR is a BOSH release that offers a uniform way to

instantiate, deploy, and manage highly available Kubernetes clusters

on a cloud platform using BOSH"

Page 36: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

What is CFCR?

• Manages Kubernetes packages & dependencies– Up to date with the k8s features

• Configurable• Tested

Page 37: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

CFCR: Leverages BOSH

• Reliable upgrades • Self-healing VMs • Certificate and Credential Management• BOSH DNS

Page 38: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

CFCR: Tooling

• Smoke Tests• Tooling for targeting Clusters

Page 39: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

Recent Work

Page 40: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

What we're working on now?

• Highly available clusters with multiple masters• The ability to backup and restore a cluster

Page 41: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

What's Next?

Page 42: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

Future Plans

• Support for Azure Cloud Provider• Hardening Security• Pluggable CNI

Page 43: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

But...we really want to hear what you think should be

next

Page 44: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

Summary

Page 45: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

Summary

• k8s is awesome! ...but hard to manage• BOSH + CFCR provides a way to ensure Day 2

operations for your k8s cluster

Page 46: Setting up Kubernetes with - Linux Foundation Events...•Prometheus: monitoring system •Zipkin: distributed tracing system •CNI plugins (calico, flannel, rkt): networking •Istio

BOSH Docs

CFCR Docs

CFCR Repo

#cfcr @ cloudfoundry.slack.com

Resources