From a06fadf9ba46f51a750b1b5d88bc02c30a031245 Mon Sep 17 00:00:00 2001 From: Archie Harris Date: Mon, 25 Mar 2019 16:58:24 +1100 Subject: [PATCH] Use different file name for processes plugin config Resubmission of PR #856 --- manifests/plugin/processes.pp | 7 ++++--- manifests/plugin/processes/process.pp | 2 +- manifests/plugin/processes/processmatch.pp | 2 +- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/manifests/plugin/processes.pp b/manifests/plugin/processes.pp index 23ff9df9e..9178f63e4 100644 --- a/manifests/plugin/processes.pp +++ b/manifests/plugin/processes.pp @@ -20,8 +20,9 @@ order => $order, interval => $interval, } + $config_file = "${collectd::plugin_conf_dir}/processes-plugin-config.conf" - concat { "${collectd::plugin_conf_dir}/processes-config.conf": + concat { $config_file: ensure => $ensure, mode => $collectd::config_mode, owner => $collectd::config_owner, @@ -32,13 +33,13 @@ concat::fragment { 'collectd_plugin_processes_conf_header': order => '00', content => epp('collectd/plugin/processes-header.conf.epp'), - target => "${collectd::plugin_conf_dir}/processes-config.conf", + target => $config_file, } concat::fragment { 'collectd_plugin_processes_conf_footer': order => '99', content => '', - target => "${collectd::plugin_conf_dir}/processes-config.conf", + target => $config_file, } if $processes { diff --git a/manifests/plugin/processes/process.pp b/manifests/plugin/processes/process.pp index 02c8d736e..197fa780a 100644 --- a/manifests/plugin/processes/process.pp +++ b/manifests/plugin/processes/process.pp @@ -17,7 +17,7 @@ 'collect_file_descriptor' => $collect_file_descriptor, 'collect_memory_maps' => $collect_memory_maps, }), - target => "${collectd::plugin_conf_dir}/processes-config.conf", + target => $collectd::plugin::processes::config_file, } } diff --git a/manifests/plugin/processes/processmatch.pp b/manifests/plugin/processes/processmatch.pp index f0b07a524..8a899a8a0 100644 --- a/manifests/plugin/processes/processmatch.pp +++ b/manifests/plugin/processes/processmatch.pp @@ -19,6 +19,6 @@ 'collect_file_descriptor' => $collect_file_descriptor, 'collect_memory_maps' => $collect_memory_maps, }), - target => "${collectd::plugin_conf_dir}/processes-config.conf", + target => $collectd::plugin::processes::config_file, } }