platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know...

57
© Copyright 2018 Pivotal Software, Inc. All rights Reserved. Version 1.0 Paul Czarkowski / @pczarkowski Principal Technologist Pivotal software BOSH: running platforms so you can run platforms on your platforms

Transcript of platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know...

Page 1: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

© Copyright 2018 Pivotal Software, Inc. All rights Reserved. Version 1.0

Paul Czarkowski / @pczarkowskiPrincipal TechnologistPivotal software

BOSH: running platforms so you can run platforms on your platforms

Page 2: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

© Copyright 2018 Pivotal Software, Inc. All rights Reserved. Version 1.0

Paul Czarkowski / @pczarkowskiPrincipal TechnologistPivotal software

Sucessful Patterns for Deploying [and Operating]Platforms.

Page 3: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

Do you know Cloud Foundry?

Page 4: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

Do you know Kubernetes ?

Page 5: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

Do you know BOSH ?

Page 6: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

What is a platform ?

https://en.wikipedia.org/wiki/Computing_platform

Page 7: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

A modern software

platform provides

API driven compute

resources.

Page 8: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

“Every IT team is a

Platform Team.”

Page 9: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy
Page 10: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

http://slides.eightypercent.net/platform-platform/index.html#1

Page 11: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

https://twitter.com/kelseyhightower/status/935252923721793536

Page 12: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

Generic Platform

API

Users

Storage Compute NetworkDatabase AccessArtifacts

Page 13: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

Enterprise IT

API

Users

SystemsAdmin

NetworkEngineer SecurityDBA QAStorage

Admin

Page 14: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy
Page 15: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

“You don’t have a platform

problem, you have a culture

problem.”

Page 16: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

InfraServices

AppPlatform

Evolve your IT teams!

Platform Team

ApplicationTeam

Build common servicesfor App Teams

Take business requirements and turn

them into features

IaaS

Virtual Infrastructure

Physical Infrastructure

Abstract infrastructure complexity with easy

consumption

DBaaSELK

App2App1 App3

Middleware

ML

Creds/CertsMessaging

???

Container ServicesContainer Hosts | Kubernetes

InfrastructureTeam

Page 17: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

People build PlatformsPeople build AppsApps run on Platforms

People are the most important componentof any platform.

Page 18: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

TraditionalTicketBasedHuman

Toil

Build App Artifact

Build App Container(s)

App → to the Platform

Container RuntimeContainer Hosts

CaaSContainer

Orchestrator

PaaSApplication Platform

IaaS

CaaS

PaaSInfrastructure

AsCode

What Abstraction is the Right One for You ?

More Control Less Complexity

IaaS API

CF API

K8s API

ConfigManagement

Build Application

Dependencies

IaaSHardware

PXE boot ?

18

Page 19: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

Hardware

IaaS

CaaS

PaaS

FaaS

Strategic goal: Push as many workloads as technically feasible to the top of the platform hierarchy

Higher flexibility and less enforcement of

standards

Lower development complexity and higher operational efficiency

Page 20: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

Hardware

IaaS

CaaS

PaaS

FaaS

InfrastructureTeam

Infrastructure TeamPlatform Team

Platform TeamInfrastructure Team

App Team

App TeamPlatform Team

App TeamPlatform Team

Infrastructure Team

Consumers of the abstraction

Page 21: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

“In general, taking something that’s already working somewhere and expanding its usage (capabilities) is far more likely to succeed than building these capabilities from scratch”

Page 22: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

Embedded OS(Windows & Linux)

NSX-T

CPI (15 methods)

v1

v2

v3...

CVEsProduct Updates Java | .NET | NodeJS

Pivotal Application Service (PAS)

Application Code & Frameworks Buildpacks | Spring Boot | Spring Cloud |

Steeltoe

Elastic | Packaged Software | Spark

Pivotal Container Service (PKS)

>cf push >kubectl run

YOU build the containerWE build the container

vSphereAzure &

Azure StackGoogle CloudAWSOpenstack

PivotalNetwork

“3Rs”

Github

Concourse

Concourse

Pivotal ServicesMarketplace

Pivotal and Partner Products

Continuousdelivery

Public Cloud Services

Customer Managed Services

Ope

n S

ervi

ce B

roke

r A

PI

Repair — CVEs

Repave Rotate — Credhub

Page 23: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy
Page 24: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

The Google Problem

x 1,000,000

Page 25: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy
Page 26: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy
Page 27: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy
Page 28: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

API Server

Kube Scheduler

K8s MasterContr

oller Manager

Etcd

C

Kubelet

Kube-proxy

K8s Worker

PodPodPod

K8s Worker

PodPodPod

K8s Worker

PodPodPod

CNI CNI CNI

Docker

Kubelet

Kube-proxy

Docker

Kubelet

Kube-proxy

Docker

Page 29: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy
Page 30: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

API Server

Kube Scheduler

K8s Master

Controller Manager

Etcd

C

Kubelet

Kube-proxy

K8s Worker

PodPod

Pod

K8s Worker

PodPod

Pod

K8s Worker

PodPod

Pod

CNI CNI CNI

Docker

Kubelet

Kube-proxy

Docker

Kubelet

Kube-proxy

Docker

Google Compute Engine(hidden from user)

Google Compute Engine

Page 31: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy
Page 32: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

TraditionalTicketBasedHuman

Toil

Build App Artifact

Build App Container(s)

App → to the Platform

Container RuntimeContainer Hosts

CaaSContainer

Orchestrator

PaaSApplication Platform

IaaS

CaaS

PaaSInfrastructure

AsCode

What Abstraction is the Right One for You ?

More Control Less Complexity

IaaS API

CF API

K8s API

ConfigManagement

Build Application

Dependencies

IaaSHardware

PXE boot ?

32

Page 33: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy
Page 34: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

BOSH - Component Architecture

Director

Postgres DB

NATS

CLI

Health Monitor

Blob Store

Agent

Agent

Agent

Agent

IaaS API

Cloud Provider Interface

IaaS

BOSH provides the means to go from deployment configuration to VM creation and management. It includes interfaces for Azure, vSphere, AWS, GCP, and OpenStack. Additional CPI can be written for alternative IaaS providers.

Registry

Page 35: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

w

BOSH - Service Deployment

Manifest

Release

Stemcell

Deployment

Page 36: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

BOSH - Stemcell

Stemcell

▪ Secured, Hardened, and Versioned Operating System image wrapped with IaaS specific packaging

▪▪ Contains a bare minimum OS skeleton with a few

common utilities pre-installed, a BOSH Agent, and a few configuration files to securely configure the OS by default.

▪▪ Images come in two flavors Ubuntu 14.04 and CentOS

7 for all IaaS’ supported▪▪ Maintained by BOSH team and available at

http://bosh.io/stemcells

Page 37: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

BOSH - Release

Job(s)

Package(s)

Monit

Packaging

Spec

Spec

Src

Blobs

Dependency Tree:

Organization:Elements:

Jobs - Pieces of the service or application you are releasing, including how to compile & run them

Packages - Provide source code and dependencies to jobs

Src - Non-binary files which is provided to packages

Blobs - Provide binary files (other than those checked into a source code repository) to packages

Monit - Script utilized to start/stop/restart the job

Packaging - Script utilized to compile the source needed by a job

Spec - Key/Value file which stores all configuration properties which can be set externally

Green - Script (erb or bash)Orange - Properties (yml)

Page 38: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

BOSH - Manifest

▪ Deployment Identification: A name for the deployment and the UUID of the Director managing the deployment

▪ Releases Block: Name and version of each release in a deployment

▪ Stemcells Block: Name and version of each stemcell in a deployment

▪ Update Block: Defines how BOSH updates instances during deployment

▪ Instance Groups Block: Configuration and resource information for instance groups (Jobs)

▪ Properties Block: Describes global properties and generalized configuration information

Required Blocks:

YAML - Primer found at end of presentation

Provides the ability to customize BOSH releases (your service)

Page 39: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

BOSH - Service Deployment

Director

Postgres DB

NATS

CLI

Health Monitor

Blob Store

IaaS API

Cloud Provider Interface

Registry

Stemcell

*

Release

Agent

*

Manifest

Agent

Agent

Agent

Config

Page 40: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

BOSH - Process High Availability

Director

NATSAgent

Agent

IaaS

Proc-1

Proc-1

Restart! Health Monitor

Alert Sent!

Page 41: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

BOSH - VM High AvailabilityManifest - Desired State

Director

NATS

Agent

Proc-1

Agent

IaaS

Proc-1

Health Monitor Agent

Proc-1

Alert Sent!

Agent

Agent

Proc-1

Proc-1=IaaS API

Cloud Provider Interface

Page 42: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

BOSH - Canary Upgrades

Manifest -

AgentAgent

Agent

Agent

Code Update 4.04!

Any update error causes the deployment to stop. Since only canaries are affected before an update stops, problem jobs

and packages are prevented from taking over all instances.

Page 43: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

BOSH - Day 2 OpsConsistent, Reliable, Scalable, Secure

▪ Checks against “desired state to return consistency

▪ No ad hoc automation burden▪ Manage services, not servers▪ 4 layers of Self Healing

ProvisionDeploy

and Configure

Monitor and

DetectRe-mediate

CurrentState

DesiredState

Page 44: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy
Page 45: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy
Page 46: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy
Page 47: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

IaaS

Node

NodeKubernetes

Cluster Services

API

Cluster3

NSX-T

vSphere

PKS includes:• PKS Control Plane, CFCR• NSX-T, Harbor, GCP Broker• BOSH Release for Kubernetes• Configures Day 1 of

- CFCR- vSphere- NSX Integration- Harbor

• Manages Day 2 of Kubernetes Clusters

- Scaling- Patching- Upgrades- Failures

Kubo CFCR

Kubernetes(As a Bosh Release)

BOSH(Deploys/Manages VMs)

CPI

CNI

HarborPrivate Container

Registry

PKS “How it Works”The value of BOSH

Node

Node

Node

Kubernetes Cluster Services

API

Node

Node

Node

Kubernetes Cluster Services

API

Node

Cluster1

Cluster2

GCPService Broker

API

#pks create-cluster K8s-1 -n 3#pks create-cluster K8s-2 -n 3#pks create-cluster K8s-3 -n 3# pks create-cluster --plan small Cluster3

PKS Control Plane

VM

VM

VM

VM

VM

VM

VM

VM

VM

Node

NodeKubernetes

Cluster Services

API

Cluster3 Node

Node

Node

VM

VM

VM

VM

VM

Page 48: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy
Page 49: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

Hardware

IaaS

CaaS

PaaS

FaaS

HPE, Dell, IBM, Lenovo

AWS, Azure, GCP, Openstack, VMWare

PKS, GKE, OpenShift, AWS

Fargate, Kubernetes

PCF, Azure App Service, Heroku, Deis

AWS Lambda, Azure Functions, OpenWhisk,

kubeless, PFS

Page 50: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy
Page 51: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy
Page 52: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy
Page 53: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

http://www.bsielearning.com.au/keep-simple-stupid/

Page 54: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

Full Opensource DIY

● ??? pxe ● Openstack Ansible● Kubespray● Ansible Hardening

https://github.com/openstack/openstack-ansible

https://github.com/openstack/ansible-hardening

https://github.com/kubernetes-incubator/kubespray

Page 55: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

!!!

Page 56: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

PLATFORM VALUE STREAM AND METRICS

REPLATFORM > MODERNIZE > OPTIMIZE

ESTABLISH, MEASURE AND UPDATE KEY OBJECTIVES AND RESULTS (OKRs)

SPEED & AGILITY STABILITY

SCALABILITY SAVINGS

$SECURITY

40-60%*More Projects With Same Staff

MillionsAnnual Savings on HW, SW and Support

25-50%*Fewer Support Incidents

40%*Faster Patching Delivery @ Zero Downtime

-90%*Time to Scale

$

$

%

How We Think about the Business Case

Page 57: platforms can run platforms on your BOSH: running ... · Do you know Cloud Foundry? Do you know Kubernetes ? Do you know BOSH ? What is a platform ? ... Docker Kubelet Kube-pro xy

Questions ?

THE END