MCPcopy Index your code
hub / github.com/screego/server / startServer

Function startServer

server/server.go:30–42  ·  view source on GitHub ↗
(mux *mux.Router, address, cert, key string)

Source from the content-addressed store, hash-verified

28}
29
30func startServer(mux *mux.Router, address, cert, key string) (*http.Server, chan error) {
31 srv := &http.Server{
32 Addr: address,
33 Handler: mux,
34 }
35
36 shutdown := make(chan error)
37 go func() {
38 err := listenAndServe(srv, address, cert, key)
39 shutdown <- err
40 }()
41 return srv, shutdown
42}
43
44func listenAndServe(srv *http.Server, address, cert, key string) error {
45 var err error

Callers 1

StartFunction · 0.85

Calls 1

listenAndServeFunction · 0.85

Tested by

no test coverage detected