[server] Stop exposing /metrics for self-hosted users (#2569)
Doesn't impact Ente's production instances since this endpoint was
disallowed on the load balancer, but instead of requiring the same for
folks who are self hosting we modify the source to not expose /metrics
on :8080 (they'll still be available on :2112).
Refs:
-
2199a42d96/middleware.go (L345)
- https://github.com/ente-io/ente/discussions/2562
This commit is contained in:
@@ -353,7 +353,7 @@ func main() {
|
||||
|
||||
p := ginprometheus.NewPrometheus("museum")
|
||||
p.ReqCntURLLabelMappingFn = urlSanitizer
|
||||
p.Use(server)
|
||||
server.Use(p.HandlerFunc())
|
||||
|
||||
// note: the recover middleware must be in the last
|
||||
server.Use(requestid.New(), middleware.Logger(urlSanitizer), cors(), gzip.Gzip(gzip.DefaultCompression), middleware.PanicRecover())
|
||||
|
||||
Reference in New Issue
Block a user