-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathfilebeat.yml
39 lines (33 loc) · 1.08 KB
/
filebeat.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
filebeat.inputs:
- type: container
paths:
- '/var/lib/docker/containers/*/*.log'
processors:
- add_docker_metadata:
host: "unix:///var/run/docker.sock"
- decode_json_fields:
fields: ["message"]
target: "json"
overwrite_keys: true
output.elasticsearch:
hosts: ["elasticsearch:9200"]
indices:
- index: "filebeat-elastic-%{[agent.version]}-%{+yyyy.MM.dd}"
when.or:
- equals:
container.image.name: docker.elastic.co/beats/filebeat:7.2.0
- equals:
container.image.name: docker.elastic.co/elasticsearch/elasticsearch:7.2.0
- equals:
container.image.name: docker.elastic.co/kibana/kibana:7.2.0
- index: "filebeat-minitwit-%{[agent.version]}-%{+yyyy.MM.dd}"
when.or:
- equals:
container.image.name: ${ELK_USER}/minitwitserver
- equals:
container.image.name: ${ELK_USER}/minitwitclient
- index: "filebeat-ngix-%{[agent.version]}-%{+yyyy.MM.dd}"
when.equals:
container.image.name: nginx
logging.json: true
logging.metrics.enabled: false