Last active
July 29, 2018 12:41
-
-
Save viveksyngh/c3d16f0cb5f387c3fc45df6a641c0a8b to your computer and use it in GitHub Desktop.
OpenFaaS function in a gist
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package function | |
| import ( | |
| "fmt" | |
| ) | |
| // Handle a serverless request | |
| func Handle(req []byte) string { | |
| return fmt.Sprintf("Hello, Go. You said: %s", string(req)) | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| provider: | |
| name: faas | |
| gateway: http://127.0.0.1:8080 | |
| functions: | |
| gist-fn: | |
| lang: go | |
| handler: ./ | |
| image: gist-fn |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment