prometheus/consoles/federation_template_example.txt
Brian Brazil 5adcec3018 Proof of concept for federation via console templates.
This exposes samples via the console templates in the
text exposition format, which the parser will fall back to.

This is not a proper federation solution, but should tide us
over for now. Extenions could include passing in a query or queries in
the url parameters.
2015-02-18 23:21:33 +00:00

4 lines
351 B
Plaintext

{{/* 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 }}