Slide 1

Slide 1 text

Cloud Run… everything you need without K8S France DevOps

Slide 2

Slide 2 text

Julien Landuré @jlandure jlandure.dev Google Developer Expert - Cloud CTO Group - Zenika GDG Cloud Nantes & DevFest Organizer devfest.gdgnantes.com

Slide 3

Slide 3 text

Back to the future...

Slide 4

Slide 4 text

App Engine in 2010

Slide 5

Slide 5 text

App Engine One of the first PaaS Limited runtimes Need specific libraries Vendor lock in Easy deployment Custom domain name Traffic splitting between versions Embed a stateful solution (datastore) Automatic CDN Scaling from 0 to N

Slide 6

Slide 6 text

Value x Complexity

Slide 7

Slide 7 text

App Engine

Slide 8

Slide 8 text

Containerization

Slide 9

Slide 9 text

Docker in 2016

Slide 10

Slide 10 text

Docker Universal package manager Dockerfile syntax Installation of Docker & CLI Daemon options & linux concepts Security Open Source Reproductible & ephemeral concepts Work with any runtime Start containers quickly Very Popular: many images & cloud services available

Slide 11

Slide 11 text

Value x Complexity

Slide 12

Slide 12 text

No content

Slide 13

Slide 13 text

2017: AKS & EKS 2016: Kubernetes adoption by CNCF 2015: GKE 2014: Kubernetes 2013: Docker 2008: LXC 2007: cgroups

Slide 14

Slide 14 text

Orchestration

Slide 15

Slide 15 text

Kubernetes in 2018

Slide 16

Slide 16 text

Kubernetes Container orchestration at scale New concepts: pods, services etc. Yaml syntax Popular: well documented Supported by all cloud providers Made to solve scaling issues Pet vs Cattle Desired State vs Actual State

Slide 17

Slide 17 text

Value x Complexity

Slide 18

Slide 18 text

Wait! Kubernetes can do so much...

Slide 19

Slide 19 text

Kubernetes… again Container orchestration at scale Automated rollouts and rollbacks Health checking Load Balancing Custom domain & traffic splitting with Traefik Service Mesh with Istio Scale from 0 with Knative or KEDA Runtime security with Falco Upgrade components Stateful objects Backup Security IAM Pricing

Slide 20

Slide 20 text

Value x Complexity

Slide 21

Slide 21 text

Kubernetes

Slide 22

Slide 22 text

Serverless

Slide 23

Slide 23 text

Cloud Run in 2019 Cloud Functions App Engine Cloud Run

Slide 24

Slide 24 text

Cloud Run One of the first serverless container solution HTTP only (gRPC) Need IaC to deploy a complete infra Container contract - Listen on 0.0.0.0 - HTTP server must start < 4 min - Request time < 60 min - Stateless - No background activity Pricing Model Easy deployment Custom domain name Traffic splitting between versions Portability of containers Buildpacks available Scaling from 0 to N No vendor lock in with Knative

Slide 25

Slide 25 text

Value x Complexity

Slide 26

Slide 26 text

Serverless computing refers to the concept of building and running applications that do not require server management. It describes a finer-grained deployment model where applications, bundled as one or more functions, are uploaded to a platform and then executed, scaled, and billed in response to the exact demand needed at the moment. Serverless definition https://github.com/cncf/wg-serverless/tree/master/whitepapers/serverless-overview

Slide 27

Slide 27 text

Value x Complexity

Slide 28

Slide 28 text

Cloud Run

Slide 29

Slide 29 text

Virtual Machine OS Application Runtime Application Virtual Hardware Dedicated Server OS Application Runtime Application Virtual Hardware Containers OS Application Runtime Application Virtual Hardware Functions Functions Functions Application Platform OS Application Runtime Application Virtual Hardware Functions Serverless OS Application Runtime Application Virtual Hardware Functions Infrastructure Container Platform Function Compute Engine Kubernetes Engine App Engine Cloud Functions On-Premises Serverless Zone Physical Hardware Cloud Run

Slide 30

Slide 30 text

Containers Any language Any library Any binary Ecosystem of base images .js .rb .go .py .sh … 0 1 0 1 0 0 1 1 1

Slide 31

Slide 31 text

Cloud Run Fully managed, deploy your workloads and don’t see the cluster. Cloud Run on Anthos Deploy into Anthos, run serverless side-by-side with your existing workloads. Knative Everywhere Use the same APIs and tooling anywhere you run Kubernetes with Knative. Serverless containers with Knative & Cloud Run

Slide 32

Slide 32 text

Container contract Listen on 0.0.0.0 on port $PORT (default 8080) HTTP server must start < 4 min (timeout → 504) Request time < 60 min (default → 5 min) Stateless (in-memory file system, doesn’t persist) Computation only within request (No background activity)

Slide 33

Slide 33 text

Container resources 1 vCPU per container instance (configurable to 4vCPU) 512 MiB of memory up to a max of 8 GiB (configurable) 80 concurrent requests per container (configurable 1-1000) 1000 max containers by default (configurable 1-1000) Access to a Metadata Server Sandboxed by gVisor

Slide 34

Slide 34 text

Pay per use CPU / Memory / Requests 100ms Pay per use

Slide 35

Slide 35 text

Good fit? Constraints? Good fit Stateless HTTP request-response workloads Scale: way up, down to zero, bursty Any runtime: any language, any dependencies, etc Constraints Must use containers No background tasks

Slide 36

Slide 36 text

Demo 🤞

Slide 37

Slide 37 text

● Cloud Run covers the majority of app use cases ● One of the TOP project Google Cloud ● Replacement of my beloved App Engine ● Interoperable (supported by Knative/eventing) ● Superior Dev Experience (local emulator & buildpacks) My point of view

Slide 38

Slide 38 text

Serverless trends State of Serverless 2020 report

Slide 39

Slide 39 text

● 👍 Kubernetes and Serverless can support each other ● 😱 Serverless container solutions are the future Cloud Run is one of the TOP project Google Cloud Release of AWS App Runner & Preview of Azure Container Instance ● 💪 The right tool to do the right thing ● 🤔 Find your way: more a Dev (Serverless World) or an Admin (K8S World) To sum up

Slide 40

Slide 40 text

Thank You! Julien Landuré @jlandure jlandure.dev