Files
fn-serverless/api/server/server_options.go
2016-12-29 20:19:42 +01:00

12 lines
218 B
Go

package server
import "context"
type ServerOption func(*Server)
func EnableShutdownEndpoint(halt context.CancelFunc) ServerOption {
return func(s *Server) {
s.Router.GET("/shutdown", s.handleShutdown(halt))
}
}