X-Git-Url: https://git.openstreetmap.org./chef.git/blobdiff_plain/1f0f157db2cbd3a43aef04904cf0fb8e231978e4..c810e6117c2e4e131aa859942566e2734e815148:/cookbooks/prometheus/templates/default/chef.prom.erb diff --git a/cookbooks/prometheus/templates/default/chef.prom.erb b/cookbooks/prometheus/templates/default/chef.prom.erb index 831a3a526..13b753ef1 100644 --- a/cookbooks/prometheus/templates/default/chef.prom.erb +++ b/cookbooks/prometheus/templates/default/chef.prom.erb @@ -3,3 +3,13 @@ <% node.interfaces do |interface| -%> chef_network_interface{name="<%= interface[:interface] %>",role="<%= interface[:role].to_s %>",family="<%= interface[:family].to_s %>"} 1 <% end -%> +# HELP chef_role Information about chef roles +# TYPE chef_role gauge +<% node[:roles].sort.each do |role| -%> +chef_role{name="<%= role %>"} 1 +<% end -%> +<% if node[:roles].include?("tilecache") -%> +# HELP chef_tile_parent Information about tile cache parents +# TYPE chef_tile_parent gauge +chef_tile_parent{name="<%= node[:tilecache][:tile_parent].split(".").first %>"} 1 +<% end -%>