Sunteți pe pagina 1din 18

Knative for developers

Greg Haynes IBM


Topics

High level overview / resources

Knative serving

Demo

Greg Haynes IBM


“(Knative) provides the building blocks for
serverless platforms to run on top of
Kubernetes.”

Source: https://www.ibm.com/blogs/cloud-computing/2018/07/24/ibm-cloud-google-knative-serverless/
Greg Haynes IBM
“(Knative) provides the building blocks for
serverless platforms to run on top of
Kubernetes.”

Source: https://www.ibm.com/blogs/cloud-computing/2018/07/24/ibm-cloud-google-knative-serverless/
Greg Haynes IBM
“(Knative) provides the building blocks for
serverless platforms to run on top of
Kubernetes.”

It’s a toolkit / framework

Source: https://www.ibm.com/blogs/cloud-computing/2018/07/24/ibm-cloud-google-knative-serverless/
Greg Haynes IBM
“(Knative) provides the building blocks for
serverless platforms to run on top of
Kubernetes.”

‘Blocks’ are a K8s CRD + Operator (Controller)

Source: https://www.ibm.com/blogs/cloud-computing/2018/07/24/ibm-cloud-google-knative-serverless/
Greg Haynes IBM
K8s Resources

Pod Pod

Node Node

Greg Haynes IBM


K8s Resources

...

Deployment

Pod Pod

Node Node

Greg Haynes IBM


Knative Resources
Service Build Feed ...

K8s Resources ...

Deployment

Pod Pod

Node Node

Greg Haynes IBM


Knative Resources
Build
Build
Build Template

Auto- Config
scaler Bus Channel Flow

Revision Route Service Cluster


Subscr. Bus Feed

Event Event
Src Type
Serving Eventing
Greg Haynes IBM
Why Resources?

As a user the internal blocks are exposed in a familiar way

As a operator the blocks can be integrated / plugged out

As a contributor there is a clear mechanism for loose coupling

Greg Haynes IBM


Knative Serving

Greg Haynes Source: https://github.com/knative/docs/tree/master/serving IBM


Knative Serving
1. configuration:
revisionTemplate:
spec:
container:
image: {image}

Greg Haynes Source: https://github.com/knative/docs/tree/master/serving IBM


Knative Serving
1. configuration:
revisionTemplate:
spec:
container:
image: {image}
2.
Config controller
Creates a revision

Greg Haynes Source: https://github.com/knative/docs/tree/master/serving IBM


Knative Serving
1. configuration:
revisionTemplate:
spec:
container:
image: {image}
2.
Config controller
3. Creates a revision
traffic:
- configurationName: {config}
percent: 100

Greg Haynes Source: https://github.com/knative/docs/tree/master/serving IBM


Knative Serving
Complete routed app
apiVersion: serving.knative.dev/v1alpha1
kind: Service
metadata:
name: helloworld
spec:
runLatest:
configuration:
revisionTemplate:
spec:
container:
image: {image}

Greg Haynes Source: https://github.com/knative/docs/tree/master/serving IBM


Scaling up/down
Istio
Route Revision

Deployment Resize Autoscaler


Activate

Stats
Activator queue-proxy
My
Service

Greg Haynes IBM


Demo

S-ar putea să vă placă și