MCPcopy Create free account
hub / github.com/docker/go-plugins-helpers / Serve

Method Serve

sdk/handler.go:32–38  ·  view source on GitHub ↗

Serve sets up the handler to serve requests on the passed in listener

(l net.Listener)

Source from the content-addressed store, hash-verified

30
31// Serve sets up the handler to serve requests on the passed in listener
32func (h Handler) Serve(l net.Listener) error {
33 server := http.Server{
34 Addr: l.Addr().String(),
35 Handler: h.mux,
36 }
37 return server.Serve(l)
38}
39
40// ServeTCP makes the handler to listen for request in a given TCP address.
41// It also writes the spec file in the right directory for docker to read.

Callers 6

TestHandlerFunction · 0.95
TestHandlerFunction · 0.95
ServeTCPMethod · 0.95
ServeUnixMethod · 0.95
ServeWindowsMethod · 0.95
TestVolumeDriverFunction · 0.80

Calls

no outgoing calls

Tested by 3

TestHandlerFunction · 0.76
TestHandlerFunction · 0.76
TestVolumeDriverFunction · 0.64