4 ms·
Introduction to Serverless Golang with OpenFaaS [video]
- alexellisuk 6y agoI was joined by Taylor Dolezal for this live stream and was surprised to learn that Taylor has not only tried OpenFaaS before, but used it in two jobs - including at Disney. After the intro, we talk a bit about Go features like testing and newer features like generics, before going into a bit of a deep dive coding session, building up functions from scratch in Golang. The functions built with OpenFaaS are actually containers with a HTTP server inside, so they can be deployed to Kubernetes, Cloud Run or Knative in a similar way. They would probably also work with fly (but I haven't tried that yet) The "workload" definition is HTTP on port 8080 and a health check (configurable) https://docs.openfaas.com/reference/workloads/ https://docs.openfaas.com/reference/workloads/ For folks starting out with FaaS and not ready to go full-on K8s, faasd might be a good option to explore - https://github.com/openfaas/faasd https://github.com/openfaas/faasd - it has containerd and CNI (just like K8s) but no clustering so it's faster and has a sub-second cold-start.