summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJesse Luehrs <doy@tozt.net>2020-07-05 16:54:02 -0400
committerJesse Luehrs <doy@tozt.net>2020-07-05 16:54:02 -0400
commit0ad2ff4de43bdd18b7ad9cce8a2712138e051b0c (patch)
tree81168d3b7b5c09caeadf56296fe7a00c0ba4ab45
parent51b72c75042d2b2521fffa031e6351904cc336d9 (diff)
downloadpuppet-tozt-0ad2ff4de43bdd18b7ad9cce8a2712138e051b0c.tar.gz
puppet-tozt-0ad2ff4de43bdd18b7ad9cce8a2712138e051b0c.zip
add smart monitoring for telegraf
-rw-r--r--modules/partofme/manifests/monitoring.pp2
-rw-r--r--modules/tick/manifests/client/plugin/smart.pp13
2 files changed, 15 insertions, 0 deletions
diff --git a/modules/partofme/manifests/monitoring.pp b/modules/partofme/manifests/monitoring.pp
index 09bf5f7..c84f9f7 100644
--- a/modules/partofme/manifests/monitoring.pp
+++ b/modules/partofme/manifests/monitoring.pp
@@ -70,4 +70,6 @@ class partofme::monitoring {
}
include tick::client::base_plugins
+
+ class { "tick::client::plugin::smart": }
}
diff --git a/modules/tick/manifests/client/plugin/smart.pp b/modules/tick/manifests/client/plugin/smart.pp
new file mode 100644
index 0000000..21c1254
--- /dev/null
+++ b/modules/tick/manifests/client/plugin/smart.pp
@@ -0,0 +1,13 @@
+class tick::client::plugin::smart {
+ tick::client::plugin { "smart":
+ opts => {
+ use_sudo => true,
+ attributes => true,
+ }
+ }
+
+ file { "/etc/sudoers.d/telegraf-smart":
+ source => 'puppet:///modules/tick/plugins/smart.sudoers',
+ require => Package['sudo'];
+ }
+}