aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMicah Anderson <micah@riseup.net>2009-02-21 12:41:10 -0500
committerMicah Anderson <micah@riseup.net>2009-02-21 12:41:10 -0500
commit3bb4c0d553e560d17b3310e4f933205eaa187fe9 (patch)
tree31ed929443abffabfaf344314d6b692e2776bd0e
parentcb436a7e3920e3fa70cf997d2e9da5c2ad81bfee (diff)
downloadpuppet-virtual-3bb4c0d553e560d17b3310e4f933205eaa187fe9.tar.gz
puppet-virtual-3bb4c0d553e560d17b3310e4f933205eaa187fe9.tar.bz2
move vserver munin plugins into the virtual module
-rw-r--r--manifests/vserver.pp56
1 files changed, 56 insertions, 0 deletions
diff --git a/manifests/vserver.pp b/manifests/vserver.pp
index cea83bc..457c904 100644
--- a/manifests/vserver.pp
+++ b/manifests/vserver.pp
@@ -44,6 +44,62 @@ class vserver::host {
# source => "puppet://$server/virtual/hashify.cron.daily",
# mode => 0755, owner => root, group => root;
}
+ locales { $fqdn: }
+
+ # remove dummy interfaces on the host
+ delete_lines { modules_dummy:
+ file => "/etc/modules",
+ pattern => "^dummy",
+ }
+
+ # Remove these dummy interfaces, they are annoying and we dont need them
+ file {
+ "/etc/modprobe.d/local-dummy":
+ ensure => absent,
+ mode => 0644, owner => root, group => root;
+
+ "/usr/local/share/munin-plugins/vserver_resources":
+ source => "$puppet://virtual/munin/vserver_resources",
+ mode => 0755, owner => root, group => root;
+
+ "/usr/local/share/munin-plugins/vserver_cpu_":
+ source => "$puppet://virtual/munin/vserver_cpu_",
+ mode => 0755, owner => root, group => root;
+
+ "/usr/local/share/munin-plugins/vserver_loadavg":
+ source => "$puppet/virtual/munin/vserver_loadavg",
+ mode => 0755, owner => root, group => root;
+ }
+
+ # This creates a load average graph combining the individual load averages of each vserver on the host
+ munin::plugin {
+ "vserver_loadavg":
+ config => "user root\n",
+ script_path => "/usr/local/share/munin-plugins";
+ }
+
+ # This creates a RSS graph for each vserver on the host (note after more than 4 vservers this can get noisy)
+ munin::plugin {
+ "vserver_resources_RSS":
+ ensure => "vserver_resources",
+ config => "user root\nenv.resource RSS",
+ script_path => "/usr/local/share/munin-plugins";
+ }
+
+ # This creates a VM graph for each vserver on the host (note after more than 4 vservers this can get noisy)
+ munin::plugin {
+ "vserver_resources_VM":
+ ensure => "vserver_resources",
+ config => "user root\nenv.resource VM",
+ script_path => "/usr/local/share/munin-plugins";
+ }
+
+ # This creates a VM graph for each vserver on the host (note after more than 4 vservers this can get noisy)
+ munin::plugin {
+ "vserver_cpu_":
+ config => "user root\n",
+ script_path => "/usr/local/share/munin-plugins";
+ }
}
define vs_create($in_domain, $context, $legacy = false, $distro = 'etch', $debootstrap_mirror = 'http://ftp.debian.org/debian') {