/serverless-knative-example

Example on how to use the Serverless Framework to deploy Knative workloads on Kubernetes clusters

Primary LanguageDockerfile

Serverless Knative Example

Example on how to use the Knative provider plugin for the Serverless Framework to deploy Knative workloads on Kubernetes clusters.

Prerequisits

Knative installation

Follow this tutorial if you need to install Knative on your Kubernetes cluster.

Quickstart

  1. Run serverless install --url https://github.com/pmuens/serverless-knative-example
  2. Run cd serverless-knative-example
  3. Run npm install
  4. Create a docker-creds.json file in the root of this project and add your Docker Hub credentials (see below for file structure)
  5. Generate a kubeconfig file (follow this tutorial if you use the Google Cloud Platform)
  6. Run serverless deploy
  7. Run serverless invoke -f helloWorld
  8. Run serverless remove

docker-creds.json

{
  "username": "jdoe",
  "password": "S0M3P455W0RD"
}