Merge pull request #542 from prometheus/I-cant-believe-its-not-federation

Proof of concept for federation via console templates.
This commit is contained in:
Julius Volz 2015-02-19 00:23:39 +01:00
commit 2dd70b8c13
1 changed files with 3 additions and 0 deletions

View File

@ -0,0 +1,3 @@
{{/* Adjust the query below to select the samples to expose. */}}
{{ range query "{__name__=~'^job:.*'}" }}
{{ .Labels.__name__ }}{{ "{" }}{{ range $k, $v := .Labels }}{{ if ne "__name__" $k }}{{ $k }}="{{ $v | reReplaceAll "([\\\\\"])" "\\$1" | reReplaceAll "\n" "\\n"| safeHtml }}",{{ end }}{{ end }}{{ "}" }} {{ print .Value | safeHtml }}{{ end }}