0
Fork 0
mirror of https://github.com/willnorris/imageproxy.git synced 2024-12-16 21:56:43 -05:00

cmd/imageproxy: use http.DefaultServeMux

this allows using the net/http/pprof package, and any other similar
package that registers handlers on the default ServerMux.
This commit is contained in:
Will Norris 2019-10-13 11:07:20 -07:00
parent 594376fc0f
commit 3b850734af

View file

@ -108,7 +108,8 @@ func main() {
}
fmt.Printf("imageproxy listening on %s\n", server.Addr)
log.Fatal(server.ListenAndServe())
http.Handle("/", p)
log.Fatal(http.ListenAndServe(*addr, nil))
}
// tieredCache allows specifying multiple caches via flags, which will create