function

package module
v0.0.0-...-4ada354 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 11, 2022 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Bindings = []apps.Binding{
	{
		Location: apps.LocationCommand,
		Bindings: []apps.Binding{
			{
				Icon:        "icon.png",
				Label:       "hello-serverless",
				Description: "Hello Serverless app",
				Hint:        "[send]",
				Bindings: []apps.Binding{
					{
						Label: "send",
						Form: &apps.Form{
							Title: "Hello, serverless!",
							Icon:  "/static/icon.png",
							Fields: []apps.Field{
								{
									Type: apps.FieldTypeText,
									Name: "message",
								},
							},
							Submit: apps.NewCall("/send"),
						},
					},
				},
			},
		},
	},
}
View Source
var DeployType apps.DeployType

DeployType is used to set, and then display how the app's instance is actually running (deployed as).

Functions

func Handle

func Handle(w http.ResponseWriter, req *http.Request)

Handler is used exclusively for OpenFaaS and faasd, as the main entry-point. The name `Handler` appears hardcoded in the OpenFaas template used to build the image.

`golang-middleware` template makes use of `http.DefaultServeMux`, so we just need to add our handlers and serve, like we do in AWS or HTTP deployments.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL