diff --git a/web/static/css/prometheus.css b/web/static/css/prometheus.css
index d46ae56b85..7e76a5b32f 100644
--- a/web/static/css/prometheus.css
+++ b/web/static/css/prometheus.css
@@ -35,6 +35,10 @@ input:not([type=submit]):not([type=file]):not([type=button]) {
float: right;
}
+table tbody th {
+ text-align: left;
+}
+
input {
margin: 0;
border: 1px solid gray;
diff --git a/web/status.go b/web/status.go
index b20bb9b4f8..fb60905f4e 100644
--- a/web/status.go
+++ b/web/status.go
@@ -14,6 +14,7 @@
package web
import (
+ "flag"
"github.com/prometheus/prometheus/appstate"
"github.com/prometheus/prometheus/retrieval"
"net/http"
@@ -25,6 +26,7 @@ type PrometheusStatus struct {
Status string
TargetPools map[string]*retrieval.TargetPool
BuildInfo map[string]string
+ Flags map[string]string
}
type StatusHandler struct {
@@ -32,12 +34,19 @@ type StatusHandler struct {
}
func (h *StatusHandler) ServeHTTP(w http.ResponseWriter, r *http.Request) {
+ flags := map[string]string{}
+
+ flag.VisitAll(func(f *flag.Flag) {
+ flags[f.Name] = f.Value.String()
+ })
+
status := &PrometheusStatus{
Config: h.appState.Config.ToString(0),
Rules: "TODO: list rules here",
Status: "TODO: add status information here",
TargetPools: h.appState.TargetManager.Pools(),
BuildInfo: h.appState.BuildInfo,
+ Flags: flags,
}
executeTemplate(w, "status", status)
}
diff --git a/web/templates/status.html b/web/templates/status.html
index e1a239eb1a..b8a63a69cb 100644
--- a/web/templates/status.html
+++ b/web/templates/status.html
@@ -38,12 +38,28 @@
Build Info
- {{range $key, $value := .BuildInfo}}
-
- {{$key}} |
- {{$value}} |
-
- {{end}}
+
+ {{range $key, $value := .BuildInfo}}
+
+ {{$key}} |
+ {{$value}} |
+
+ {{end}}
+
+
+
+
+ Startup Flags
+
+
+
+ {{range $key, $value := .Flags}}
+
+ {{$key}} |
+ {{$value}} |
+
+ {{end}}
+
{{end}}