serverless / serverless-kubeless

This plugin enables support for Kubeless within the Serverless Framework.
Apache License 2.0
303 stars 81 forks source link

is invoke local working #75

Open ericln opened 7 years ago

ericln commented 7 years ago

i m trying out sls kubeless plugin, im using the kubeless-nodejs template to create a new function. Executing the command serverless invoke local --function capitalize --data 'this is a test' --raw however, doesn't seem to return anything, am I missing something here?

sebgoa commented 7 years ago

I don't think it is supported, you need to target a kubernetes cluster that has kubeless installed.

cc/ @andresmgot

andresmgot commented 7 years ago

Yes. Right now the only way of using the plugin is to use a Kubernetes endpoint.

ericln commented 7 years ago

im not too familiar with the implementation of a plugin, can you shed some light on the effort of making it work with invoke local ? what needs to be implemented ?

andresmgot commented 7 years ago

It will be needed to mock a Kubernetes environment and redirect calls to use local runtimes binaries likenode or python.

The main reason behind not having the invoke local command yet is that in the case of Kubeless you can easily deploy a Kubernetes environment locally using Minikube that will be more similar to the production environment than local runtimes.

If you are curious this is the implementation details for the command invoke local for OpenWhisk.