Skip to content

Instantly share code, notes, and snippets.

@davyngugi
Last active April 12, 2019 08:46
Show Gist options
  • Save davyngugi/6787b9b53f774e1a3e559c4f65ecdbc4 to your computer and use it in GitHub Desktop.
Save davyngugi/6787b9b53f774e1a3e559c4f65ecdbc4 to your computer and use it in GitHub Desktop.
Filebeat JSON processors
filebeat.inputs:
# Each - is an input. Most options can be set at the input level, so
# you can use different inputs for various configurations.
# Below are the input specific configurations.
- type: log
# Change to true to enable this input configuration.
enabled: true
# Paths that should be crawled and fetched. Glob based paths.
paths:
- /path/to/logs
#- c:\programdata\elasticsearch\logs\*
processors:
- dissect:
tokenizer: "[%{date} %{time} %{level}/%{worker}] %{details}"
field: "message"
target_prefix: "extracted"
ignore_missing: true
- decode_json_fields:
fields: ["extracted.details"]
target: "json"
process_array: true
max_depth: 1
overwrite_keys: false
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment