Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/pmuens/serverless-knative-example
Example on how to use the Serverless Framework to deploy Knative workloads on Kubernetes clusters
https://github.com/pmuens/serverless-knative-example
knative kubernetes kubernetes-cluster serverless serverless-framework
Last synced: about 2 months ago
JSON representation
Example on how to use the Serverless Framework to deploy Knative workloads on Kubernetes clusters
- Host: GitHub
- URL: https://github.com/pmuens/serverless-knative-example
- Owner: pmuens
- Created: 2019-10-18T15:16:28.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2019-11-07T14:46:29.000Z (over 5 years ago)
- Last Synced: 2024-10-20T04:44:33.681Z (4 months ago)
- Topics: knative, kubernetes, kubernetes-cluster, serverless, serverless-framework
- Language: Dockerfile
- Homepage:
- Size: 3.91 KB
- Stars: 6
- Watchers: 4
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Serverless Knative Example
Example on how to use the [Knative provider plugin](https://github.com/serverless/serverless-knative) for the [Serverless Framework](https://github.com/serverless/serverless) to deploy Knative workloads on [Kubernetes](https://kubernetes.io) clusters.
## Prerequisits
- [Google Cloud SDK](https://cloud.google.com/sdk/) on your local machine
- [Node.js](https://nodejs.org/en/) >= 8 on your local machine
- [Docker](https://www.docker.com) in your local machine
- [Kubernetes Cluster](https://kubernetes.io) e.g. on the [Google Cloud Platform](https://cloud.google.com) (or your local machine)
- [Knative](https://knative.dev) on your Kubernetes Cluster## Knative installation
Follow [this tutorial](https://github.com/meteatamel/knative-tutorial/tree/5ac77498c5715775c8ed4c114bc1bee7ac09554e#installation) if you need to install Knative on your Kubernetes cluster.
## Quickstart
1. Run `serverless install --url https://github.com/pmuens/serverless-knative-example`
1. Run `cd serverless-knative-example`
1. Run `npm install`
1. Create a `docker-creds.json` file in the root of this project and add your Docker Hub credentials (see below for file structure)
1. Generate a [`kubeconfig`](https://rancher.com/docs/rancher/v2.x/en/cluster-admin/kubeconfig/) file (follow this tutorial if you use the [Google Cloud Platform](https://cloud.google.com/kubernetes-engine/docs/how-to/cluster-access-for-kubectl#generate_kubeconfig_entry))
1. Run `serverless deploy`
1. Run `serverless invoke -f helloWorld`
1. Run `serverless remove`## `docker-creds.json`
```json
{
"username": "jdoe",
"password": "S0M3P455W0RD"
}
```