Go is supported in Google functions
Renato Suero
Posted on January 17, 2019
Now we can use Go to run google functions =). Take a look an example:
// Package helloworld provides a set of Cloud Function samples.
package helloworld
import (
"fmt"
"net/http"
)
// HelloGet is an HTTP Cloud Function.
func HelloGet(w http.ResponseWriter, r *http.Request) {
fmt.Fprint(w, "Hello, World!")
}
Deploy:
gcloud functions deploy HelloGet --runtime go111 --trigger-http
💖 💪 🙅 🚩
Renato Suero
Posted on January 17, 2019
Join Our Newsletter. No Spam, Only the good stuff.
Sign up to receive the latest update from our blog.