18 lines
278 B
Go
18 lines
278 B
Go
package hello
|
|
|
|
import (
|
|
"fmt"
|
|
"net/http"
|
|
|
|
"github.com/OpenFunction/functions-framework-go/functions"
|
|
)
|
|
|
|
func init() {
|
|
functions.HTTP("Main", Main,
|
|
functions.WithFunctionPath("/"))
|
|
}
|
|
|
|
func Main(w http.ResponseWriter, r *http.Request) {
|
|
fmt.Fprintf(w, "Hello, world!\n")
|
|
}
|