-
Notifications
You must be signed in to change notification settings - Fork 753
Add support for Golang runtime #169
Comments
indeed, we created #8 a while ago, just did not have time to get to it yet. |
What needs to be done in order to support Go runtime? |
you need to create a runtime in: https://github.com/kubeless/kubeless/tree/master/docker/runtime the first thing would be to start with an http-trigger, here is an example for python: then we modify the controller a bit to know about this new runtime. However, there is a need to refactor the entire runtime handling. we need to abstract the runtime language and provide a generic trigger mechanism. |
Hi, we're evaluating Kubeless against other FaaS projects and really like it, but also we write a lot of Go functions. Is there anything I can do to help with Go support? |
Hi @davewalk great to hear. We are working on a refactor to be able to support more runtime in a much more flexible manner. But you can get started experimenting by writing a custom runtime: https://github.com/kubeless/kubeless/blob/master/docs/runtimes.md#custom-runtime-alpha Basically your own docker image that can use the language that you want. |
This might help: https://github.com/kubeless/kubeless/pull/472/files it is a new trigger (AWS SQS), it is fully functional for python function. We are not merging it because of the refactor mentioned. |
So basically what you can do right away is:
and you are good to go as a temporary "hack" |
Gotcha, I can get going on that. Didn't know if I should wait for the re-factor. Do you have a timeframe on that? |
not yet, mid-february maybe. It involves decoupling the triggers and the language runtimes. It would be nice to see what workflow you are looking for for Golang. Do you want to provide simple functions, do you want to provide a binary, do you want to pre-build a Docker image with all the dependencies ? |
Mostly simple functions. I want to write a function, tell Kubeless to run it and serve via HTTP. Our dep needs aren't crazy, the scratch image with the ability to But I could be totally taking too much for granted because I don't know Kubeless that well yet. What draws me to it though is that it's super easy to deploy ("run this function with this handler and runtime") and the K8 primitives it uses. |
I was just thinking, if you don't want to build your own custom runtime, you could write a function in Python that calls your binary. You stick the binary in a zip file with the function and deploy that. the zip file support is not yet documented but available. |
+1 for Go support. |
When you guys do this I'd be interested to see how you handle the GOPATH and whether that can support sub-modules too (like importing a sub-folder). If you want to compare notes maybe we can collaborate around it. |
will do |
+1 for Go support. |
this is coming with the beginning here #621 |
We can close this now: v0.6.0 includes support for Golang functions. Check the promotion blogpost at https://medium.com/bitnami-perspectives/introducing-golang-functions-to-kubeless-a9a9e4f0cab1 :) |
It would be awesome if Kubeless supports Go runtime. Is this planned and what needs to be done in order for this to happen?
The text was updated successfully, but these errors were encountered: