Define custom fields on root level when using multiple config yml files

In my main filebeat.yml I have
filebeat.config.inputs:
enabled: true
path: /usr/share/filebeat/configs/*.yml

So I can define multiple config files.
Each config file specifies a custom field name to add.
However this is always added as a nested field field.name .

- type: log
  enabled: true
  paths:
    - /var/log/appName.log
  fields:
    name: appName

This will give the field field.appName. I just want appName.
I tried using target: '' but that doesn't work.
How can I do that?

Hi,

https://www.elastic.co/guide/en/beats/filebeat/current/filebeat-input-log.html#fields-under-root-log

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.