Skip to content

Commit

Permalink
Make flag names consistent across projects.
Browse files Browse the repository at this point in the history
  • Loading branch information
juliusv committed Feb 8, 2015
1 parent ab55188 commit 989bc86
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions web/web.go
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,8 @@ import (

// Commandline flags.
var (
listenAddress = flag.String("web.listen-address", ":9090", "Address to listen on for web interface.")
listenAddress = flag.String("web.listen-address", ":9090", "Address to listen on for the web interface, API, and telemetry.")
metricsPath = flag.String("web.telemetry-path", "/metrics", "Path under which to expose metrics.")
useLocalAssets = flag.Bool("web.use-local-assets", false, "Read assets/templates from file instead of binary.")
userAssetsPath = flag.String("web.user-assets", "", "Path to static asset directory, available at /user.")
enableQuit = flag.Bool("web.enable-remote-shutdown", false, "Enable remote service shutdown.")
Expand Down Expand Up @@ -73,7 +74,7 @@ func (ws WebService) ServeForever() error {
))

ws.MetricsHandler.RegisterHandler()
http.Handle("/metrics", prometheus.Handler())
http.Handle(*metricsPath, prometheus.Handler())
if *useLocalAssets {
http.Handle("/static/", prometheus.InstrumentHandler(
"/static/", http.StripPrefix("/static/", http.FileServer(http.Dir("web/static"))),
Expand Down

0 comments on commit 989bc86

Please sign in to comment.