Skip to content

Commit

Permalink
add attributes for max_processes, max_graph_jobs, and max_cgi_graph_jobs
Browse files Browse the repository at this point in the history
  • Loading branch information
josephholsten committed Aug 3, 2012
1 parent 09669a5 commit ac0006a
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 0 deletions.
3 changes: 3 additions & 0 deletions README.md
Expand Up @@ -44,6 +44,9 @@ Attributes
* `node['munin']['server_role']` - role of the munin server. Default is monitoring.
* `node['munin']['docroot']` - document root for the server apache vhost. on archlinux, the default is `/srv/http/munin`, or `/var/www/munin` on other platforms.
* `node['munin']['web_server']` - supports apache or nginx, default is "apache"
* `node['munin']['max_processes']` - Maximum number of simultaneous Munin-update processes. When not set, munin will use as many as necessary. Default is to use as many as necessary.
* `node['munin']['max_graph_jobs']` - Maximum number of parallel processes used by munin-graph when calling rrdgraph, default is "6"
* `node['munin']['max_cgi_graph_jobs']` - Maximum number of parallel munin-cgi-graph or munin-fastcgi-graph jobs, default is "6"

Recipes
=======
Expand Down
3 changes: 3 additions & 0 deletions attributes/default.rb
Expand Up @@ -52,3 +52,6 @@

default['munin']['plugins'] = "#{default['munin']['basedir']}/plugins"
default['munin']['tmpldir'] = "#{default['munin']['basedir']}/templates"
default['munin']['max_graph_jobs'] = "6"
default['munin']['max_cgi_graph_jobs'] = "6"
default['munin']['max_processes'] = nil # use as many as necessary
7 changes: 7 additions & 0 deletions templates/default/munin.conf.erb
Expand Up @@ -13,10 +13,17 @@ contact.<%= kind %>.contact <%= command %>
# Where to look for the HTML templates
tmpldir <%= node['munin']['tmpldir'] %>
<% if node['munin']['max_processes'] %>
max_processes <%= node['munin']['max_processes'] %>
<% end %>
max_graph_jobs <%= node['munin']['max_graph_jobs'] %>
max_cgi_graph_jobs <%= node['munin']['max_cgi_graph_jobs'] %>

# a simple host tree
<% @munin_nodes.each do |system| -%>
[<%= system[:hostname] %>]
address <%= system[:ipaddress] %>
use_node_name yes

<% end -%>

0 comments on commit ac0006a

Please sign in to comment.