use new unified adding cmd
authormh <mh@immerda.ch>
Wed, 1 Oct 2008 22:20:36 +0000 (22:20 +0000)
committermh <mh@immerda.ch>
Wed, 1 Oct 2008 22:20:36 +0000 (22:20 +0000)
manifests/client.pp

index dcec13e..db5587f 100644 (file)
@@ -71,7 +71,7 @@ class munin::client::base {
        include munin::plugins::base
 }
 
-# currently we install munin on openbsd by hand
+# currently we install munin on openbsd by targz
 # :(
 class munin::client::openbsd inherits munin::client::base {
     file{'/usr/src/munin_openbsd.tar.gz':
@@ -94,9 +94,8 @@ class munin::client::openbsd inherits munin::client::base {
         require => Exec['extract_openbsd'],
         owner => root, group  => 0, mode => 0755;
     }
-    exec{'enable_munin_on_boot':
-        command => 'echo "if [ -x /opt/munin/sbin/munin-node ]; then echo -n \' munin\'; /opt/munin/sbin/munin-node; fi" >> /etc/rc.local',
-        unless => 'grep -q "munin-node" /etc/rc.local',
+    openbsd::add_to_rc_local{'munin-node':
+        binary => '/opt/munin/sbin/munin-node',
         require => File['/var/run/munin'],
     }
     Service['munin-node']{