blob: e94bf33e8400ee4121b0d08100cbfef10c95677c [file] [log] [blame]
Doyoung Lee7102a812019-02-10 20:41:00 -08001{{- /*
2Copyright 2017-present Open Networking Foundation
3
4Licensed under the Apache License, Version 2.0 (the "License");
5you may not use this file except in compliance with the License.
6You may obtain a copy of the License at
7
8http://www.apache.org/licenses/LICENSE-2.0
9
10Unless required by applicable law or agreed to in writing, software
11distributed under the License is distributed on an "AS IS" BASIS,
12WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13See the License for the specific language governing permissions and
14limitations under the License.
15*/ -}}
16{{- define "onos.log-agent-configmap" }}
17---
18kind: ConfigMap
19apiVersion: v1
20metadata:
21 name: log-agent-configmap
22data:
23 config: |
24 ---
25 # filebeat configuration for ONOS
26 filebeat.inputs:
27 - type: log
28 paths:
29 - "/onos_logs/karaf_json.log"
30
31 fields_under_root: true
32
33 json.keys_under_root: true
34 json.add_error_key: true
35 json.overwrite_keys: true
36 json.message_key: "message"
37
38 multiline.pattern: '^[[:space:]]'
39 multiline.negate: false
40 multiline.match: after
41
42 # remove unneeded fields
43 processors:
44 - drop_fields:
45 fields: ["host", "prospector", "input"]
46
47 output.kafka:
48 hosts: {{ .Values.log_agent.kafka_brokers | toJson }}
49 topic: 'onos.log'
50 key: '%{[bundle.name]}'
51
52{{- end }}