]> gitweb.fluxo.info Git - puppet-nodo.git/commitdiff
Configuring smart plugin, adding disks fact and adding package gitk on utils::desktop
authorSilvio Rhatto <rhatto@riseup.net>
Fri, 26 Mar 2010 02:01:03 +0000 (23:01 -0300)
committerSilvio Rhatto <rhatto@riseup.net>
Fri, 26 Mar 2010 02:01:03 +0000 (23:01 -0300)
lib/facter/disks.rb [new file with mode: 0644]
manifests/physical.pp
manifests/subsystems/utils.pp

diff --git a/lib/facter/disks.rb b/lib/facter/disks.rb
new file mode 100644 (file)
index 0000000..60975e5
--- /dev/null
@@ -0,0 +1,7 @@
+# return the list of disks
+Facter.add("disks") do
+  confine :kernel => :linux
+  setcode do
+    `egrep '[sh]d[a-z]+$' /proc/partitions | awk '{ print $4 }' | xargs`.split(' ')
+  end
+end
index bad5fe7dff94f9781e178aa7f8d370c290fb6427..3c4ad03c5137945b9fb2520436667125f1b9e36a 100644 (file)
@@ -41,4 +41,8 @@ class nodo::physical inherits nodo {
 
   # SMART monitoring
   include munin::plugins::smart
+  munin::plugin { "sda":
+    ensure => "smart_",
+    config => "user root\ngroup disk",
+  }
 }
index 0995331e1f96dc309140ec715d16827ef4f87c95..1cb55851a568b4a0fe41677b2f172e2b9464e1fc 100644 (file)
@@ -42,7 +42,7 @@ class utils::desktop {
               'gawk',              'telnet',         'fpm',
               'procmail',          'msmtp',          'netpbm',
               'gqview',            'antiword',       'mairix',
-              'mozilla-plugin-gnash' ]:
+              'gitk',              'mozilla-plugin-gnash' ]:
     ensure => installed,
   }