Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Correct hiera Syntax for telegraf::processors (with pull request #139) #179

Closed
linuxmail opened this issue Sep 6, 2021 · 1 comment
Closed

Comments

@linuxmail
Copy link

Hallo,

Affected Puppet, Ruby, OS and module versions/distributions

  • Puppet: 5.5.22-1stretch
  • Ruby: 1:2.3.3
  • Distribution: Debian Stretch
  • Module version: 3.1.0

How to reproduce (e.g Puppet code you use)

[...]
telegraf::processors:
  enum:
    - mapping:
        "field": "tx_sqltype"
        default: 1
        'value_mappings':
          select: "0"
          update: "1"
          insert: "2"

What are you seeing

 # PROCESSORS:
 #
 [[processors.enum]]
-[[processors.enum.mapping]]
+[processors.enum.mapping]
 default = 1
 field = "tx_sqltype"
 [processors.enum.mapping.value_mappings]
 insert = "2"
 select = "0"
 update = "1"
+

What behaviour did you expect instead

No changes

Any additional information you'd like to impart

I used the Puppet requests from #139 but with a different template:

[...]
#
# PROCESSORS:
#
<%= require 'toml-rb'; TomlRB.dump({'processors'=>@processors}) %>
(END)

I have no idea .. how to get the correct syntax working :-)

@linuxmail
Copy link
Author

Just solved it :-)

telegraf::processors:
  enum:
    -
      mapping:
        - default: 1
          "field": "tx_sqltype"
          'value_mappings':
            select: "0"
            update: "1"
            insert: "2"

Syntax drive me always nuts ...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants