From 316b1e5472a4d59e0c31069746876ef97c93f698 Mon Sep 17 00:00:00 2001 From: Peter Palfrader Date: Mon, 28 Aug 2017 14:35:32 +0200 Subject: [PATCH 1/1] Switch /etc/cron.d/puppet-nagios-wraps to concat --- modules/nagios/manifests/client.pp | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/modules/nagios/manifests/client.pp b/modules/nagios/manifests/client.pp index 8f2249d32..b31cd60ef 100644 --- a/modules/nagios/manifests/client.pp +++ b/modules/nagios/manifests/client.pp @@ -76,7 +76,13 @@ class nagios::client inherits nagios { ensure => absent, } - file { '/etc/cron.d/puppet-nagios-wraps': - content => "47 * * * * root /usr/sbin/dsa-wrap-nagios-check -s puppet-agent /usr/lib/nagios/plugins/dsa-check_puppet_agent -d0 -c 28800 -w 18000\n", + concat { '/etc/cron.d/puppet-nagios-wraps': } + concat::fragment { 'dsa-check_puppet_agent': + target => '/etc/cron.d/puppet-nagios-wraps', + content => @(EOF) + SHELL=/bin/bash + PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/lib/nagios/plugins + 47 * * * * root dsa-wrap-nagios-check -s puppet-agent dsa-check_puppet_agent -d0 -c 28800 -w 18000 + | EOF } } -- 2.20.1