From 7cf838ffd6888d31d5657e607497f698f21a3fc5 Mon Sep 17 00:00:00 2001 From: Zdenek Janda Date: Sun, 26 Oct 2014 17:05:38 +0100 Subject: [PATCH] New style naming and permissions for curl_json plugin --- manifests/plugin/curl_json.pp | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/manifests/plugin/curl_json.pp b/manifests/plugin/curl_json.pp index 82313726e..79e82cfce 100644 --- a/manifests/plugin/curl_json.pp +++ b/manifests/plugin/curl_json.pp @@ -5,6 +5,7 @@ $keys, $user = undef, $password = undef, + $order = '10', ) { include collectd::params @@ -12,12 +13,19 @@ $conf_dir = $collectd::params::plugin_conf_dir + # This is deprecated file naming ensuring old style file removed, and should be removed in next major relese + file { "${name}.load-deprecated": + path => "${conf_dir}/${name}.conf", + ensure => absent, + } + # End deprecation + file { "${name}.load": - path => "${conf_dir}/${name}.conf", + path => "${conf_dir}/${order}-${name}.conf", owner => 'root', group => $collectd::params::root_group, - mode => '0644', + mode => '0640', content => template('collectd/curl_json.conf.erb'), notify => Service['collectd'], }