Merge branch 'master' of github.com:tus/tusd into v1

This commit is contained in:
Marius 2019-06-16 17:00:10 +02:00
commit ab641b6f89
2 changed files with 4 additions and 1 deletions

View File

@ -33,3 +33,5 @@ WORKDIR /srv/tusd-data
EXPOSE 1080
ENTRYPOINT ["tusd"]
CMD ["--hooks-dir","/srv/tusd-hooks"]
USER tusd

View File

@ -7,6 +7,7 @@ import (
"github.com/tus/tusd/pkg/prometheuscollector"
"github.com/prometheus/client_golang/prometheus"
"github.com/prometheus/client_golang/prometheus/promhttp"
)
var MetricsOpenConnections = prometheus.NewGauge(prometheus.GaugeOpts{
@ -28,5 +29,5 @@ func SetupMetrics(handler *handler.Handler) {
prometheus.MustRegister(prometheuscollector.New(handler.Metrics))
stdout.Printf("Using %s as the metrics path.\n", Flags.MetricsPath)
http.Handle(Flags.MetricsPath, prometheus.Handler())
http.Handle(Flags.MetricsPath, promhttp.Handler())
}