Comments (5)
+1 for having this use case. We often have hosts that need to collect some service specific metrics, and adding those is a bit cumbersome.
We ended up doing this in inputs in the resource spec:
inputs => {
...
mem => [ {} ],
io => [ {} ],
net => [ {} ],
system => [ {} ]
} + lookup('ndn::telegraf.inputs', {default_value => [{}], merge => deep}),
So we could add additional inputs per host.
from puppet-telegraf.
@htj The ability to configure merge behaviour was added in #134
Does this work for you?
from puppet-telegraf.
I had several issues getting this to work. Having:
merge_hash_arrays: true
Option in common.yaml as listen in:
https://github.com/voxpupuli/puppet-telegraf/pull/99/commits
Make it possible to have multiple inputs of the same type (we often have multiple inputs.exec for custom collections)
However this did not make it possible to have multiple
telegraf::inputs:
As one would always wine. I suspect it has something to do with look hiarchy, but I don't understand Puppet well enough to debug it.
from puppet-telegraf.
The lookup_options
in https://github.com/voxpupuli/puppet-telegraf/blob/777e608c000655781179913d9ee41aacd216c8c0/data/defaults.yaml are just the defaults. You can override lookup_options
in your environments hiera, for example in your node specific hiera data. See https://puppet.com/docs/puppet/latest/hiera_merging.html#overriding-merge-behavior
If you still can't make it merge the way you need it to, could you provide some specific examples of what you're trying to achieve?
from puppet-telegraf.
Changing lookup_options
in the module to this:
---
lookup_options:
'telegraf::inputs':
merge:
strategy: deep
merge_hash_arrays: true
'telegraf::outputs':
merge:
strategy: deep
merge_hash_arrays: true
resolves the issue.
from puppet-telegraf.
Related Issues (20)
- [question] Are you open to using inifile instead of toml-rb? HOT 6
- org.jruby.exceptions.RaiseException: (LoadError) no such file to load -- toml-rb HOT 2
- Unable able to install previous versions of the module HOT 1
- Is there a way to set up multiple discreet influxdb outputs? HOT 1
- Broken $hostname default value when fact['networking'] is null HOT 1
- Problem with defining win_perf_counters input HOT 1
- Minor: Please fix the (>=5.0.0 < 7.0.0) to (>= 5.0.0 < 7.0.0) in the metadata for dependencies HOT 3
- Cannot install telegraf on Windows server because config_file_mode and config_folder_mode is undefined
- NO_PUBKEY on Ubuntu | Key has changed HOT 1
- No longer possible to configure tagpass and tagdrop HOT 1
- Release a new version with #160 included HOT 1
- Cannot use multifile plugin
- Correct hiera Syntax for telegraf::processors (with pull request #139) HOT 1
- new forge release to pickup metadata.json changes
- onceover test fail cannot load such file -- toml-rb
- InfluxData GPG key rotation
- Installs from influxdata repo can use stable repos
- telegraf user on debian now has _
- Add creates parameter to all archive resources
- Overly strict version constraint on puppetlabs-stdlib
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from puppet-telegraf.