From aaf55c9ebfa0e34f63b2ca3c2b660e1d164026dd Mon Sep 17 00:00:00 2001 From: Ewoud Kohl van Wijngaarden Date: Mon, 6 May 2013 18:13:12 +0200 Subject: lintify --- manifests/client/openbsd.pp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'manifests/client/openbsd.pp') diff --git a/manifests/client/openbsd.pp b/manifests/client/openbsd.pp index cd21abf..e3c18d5 100644 --- a/manifests/client/openbsd.pp +++ b/manifests/client/openbsd.pp @@ -4,7 +4,7 @@ class munin::client::openbsd inherits munin::client::base { if $::operatingsystemrelease == '4.3' { file{'/usr/src/munin_openbsd.tar.gz': - source => "puppet:///modules/munin/openbsd/package/munin_openbsd.tar.gz", + source => 'puppet:///modules/munin/openbsd/package/munin_openbsd.tar.gz', owner => root, group => 0, mode => '0600'; -- cgit v1.2.3 From d2a2cb77b9a9ca5deddecdec3d14ac763388929e Mon Sep 17 00:00:00 2001 From: mh Date: Sun, 3 Nov 2013 17:46:46 +0100 Subject: cleanup openbsd manual installation + remove unnecessary files The manual OpenBSD installation is now so old and not needed anymore. --- manifests/client/openbsd.pp | 40 +++------------------------------------- 1 file changed, 3 insertions(+), 37 deletions(-) (limited to 'manifests/client/openbsd.pp') diff --git a/manifests/client/openbsd.pp b/manifests/client/openbsd.pp index e3c18d5..5ced4c4 100644 --- a/manifests/client/openbsd.pp +++ b/manifests/client/openbsd.pp @@ -1,53 +1,19 @@ -# currently we install munin on openbsd by targz -# :( - +# generate a few missing things on openbsd class munin::client::openbsd inherits munin::client::base { - if $::operatingsystemrelease == '4.3' { - file{'/usr/src/munin_openbsd.tar.gz': - source => 'puppet:///modules/munin/openbsd/package/munin_openbsd.tar.gz', - owner => root, - group => 0, - mode => '0600'; - } - exec{'extract_openbsd': - command => 'cd /;tar xzf /usr/src/munin_openbsd.tar.gz', - unless => 'test -d /opt/munin', - require => File['/usr/src/munin_openbsd.tar.gz'], - before => File['/var/run/munin'], - } - package{'p5-Compress-Zlib': - ensure => installed, - before => File['/var/run/munin'], - } - } else { - package{'munin-node': - ensure => installed, - } - } - package{ [ 'p5-Crypt-SSLeay', 'p5-HTML-Parser', 'p5-HTML-Tagset', 'p5-HTTP-GHTTP', - 'p5-LWP-UserAgent-Determined', 'p5-Net-SSLeay', 'p5-Net-Server', - 'p5-URI', 'p5-libwww', 'pcre', 'curl' ]: - ensure => installed, - before => File['/var/run/munin'], - } file{[ '/var/run/munin', '/var/log/munin' ]: ensure => directory, owner => root, group => 0, mode => '0755'; } - $bin_loc = $::operatingsystemrelease ? { - '4.3' => '/opt/munin/sbin/munin-node', - default => '/usr/local/sbin/munin-node' - } openbsd::rc_local{'munin-node': - binary => $bin_loc, + binary => '/usr/local/sbin/munin-node', require => File['/var/run/munin'], } Service['munin-node']{ restart => '/bin/kill -HUP `/bin/cat /var/run/munin/munin-node.pid`', stop => '/bin/kill `/bin/cat /var/run/munin/munin-node.pid`', - start => $bin_loc, + start => '/usr/local/sbin/munin-node', status => 'test -e /var/run/munin/munin-node.pid && (ps ax | egrep -q "^ *$(cat /var/run/munin/munin-node.pid).*munin-node")', hasstatus => true, hasrestart => true, -- cgit v1.2.3 From 99e32a12d401828e71c13309bf21460086f77e0e Mon Sep 17 00:00:00 2001 From: mh Date: Wed, 29 Jan 2014 23:32:52 +0100 Subject: unify logdir --- manifests/client/openbsd.pp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'manifests/client/openbsd.pp') diff --git a/manifests/client/openbsd.pp b/manifests/client/openbsd.pp index 5ced4c4..64ea588 100644 --- a/manifests/client/openbsd.pp +++ b/manifests/client/openbsd.pp @@ -1,6 +1,6 @@ # generate a few missing things on openbsd class munin::client::openbsd inherits munin::client::base { - file{[ '/var/run/munin', '/var/log/munin' ]: + file{[ '/var/run/munin', '/var/log/munin-node' ]: ensure => directory, owner => root, group => 0, @@ -17,10 +17,10 @@ class munin::client::openbsd inherits munin::client::base { status => 'test -e /var/run/munin/munin-node.pid && (ps ax | egrep -q "^ *$(cat /var/run/munin/munin-node.pid).*munin-node")', hasstatus => true, hasrestart => true, - require => [ File['/var/run/munin'], File['/var/log/munin'] ], + require => [ File['/var/run/munin'], File['/var/log/munin-munin'] ], } cron{'clean_munin_logfile': - command => 'rm /var/log/munin/munin-node.log; kill -HUP `cat /var/run/munin/munin-node.pid`', + command => 'rm /var/log/munin-node/munin-node.log; kill -HUP `cat /var/run/munin/munin-node.pid`', minute => 0, hour => 2, weekday => 0, -- cgit v1.2.3 From 0ebbe54879941e886dc1519b7dfdc69f614975ad Mon Sep 17 00:00:00 2001 From: mh Date: Wed, 29 Jan 2014 23:37:11 +0100 Subject: correct dependency --- manifests/client/openbsd.pp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'manifests/client/openbsd.pp') diff --git a/manifests/client/openbsd.pp b/manifests/client/openbsd.pp index 64ea588..09fb24f 100644 --- a/manifests/client/openbsd.pp +++ b/manifests/client/openbsd.pp @@ -17,7 +17,7 @@ class munin::client::openbsd inherits munin::client::base { status => 'test -e /var/run/munin/munin-node.pid && (ps ax | egrep -q "^ *$(cat /var/run/munin/munin-node.pid).*munin-node")', hasstatus => true, hasrestart => true, - require => [ File['/var/run/munin'], File['/var/log/munin-munin'] ], + require => [ File['/var/run/munin'], File['/var/log/munin-node'] ], } cron{'clean_munin_logfile': command => 'rm /var/log/munin-node/munin-node.log; kill -HUP `cat /var/run/munin/munin-node.pid`', -- cgit v1.2.3