blob: 1d67294dbc529c03d2b62d71a9aef2860ec866da [file] [log] [blame]
Zack Williamsa7b3e4c2018-08-14 15:12:49 -07001---
2# Copyright 2018--present Open Networking Foundation
3#
4# Licensed under the Apache License, Version 2.0 (the "License");
5# you may not use this file except in compliance with the License.
6# You may obtain a copy of the License at
7#
8# http://www.apache.org/licenses/LICENSE-2.0
9#
10# Unless required by applicable law or agreed to in writing, software
11# distributed under the License is distributed on an "AS IS" BASIS,
12# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13# See the License for the specific language governing permissions and
14# limitations under the License.
15
16# Values file for SEBA log aggregation infra
17# NOTE: must start this chart with the name "logging":
18# helm install -n logging logging
19# ortherwise the elasticsearch hostname won't work properly in the other containers
20
21# elasticstack config
22# ref: https://github.com/helm/charts/tree/master/incubator/elasticsearch
23elasticsearch:
24 client:
25 serviceType: "NodePort"
26 master:
27 persistence:
28 storageClass: "local-ssd"
29 size: "5Gi"
30 data:
31 persistence:
32 storageClass: "local-hdd"
33 size: "10Gi"
34
35# kibana config
36# ref: https://github.com/helm/charts/tree/master/stable/kibana
37kibana:
38 enabled: true
39# dashboardImport:
40# dashboards: |-
41#
42 service:
43 type: "NodePort"
44 nodePort: 30601
45 env:
46 ELASTICSEARCH_URL: "http://logging-elasticsearch-client:9200"
47
48# logstash config
49# ref: https://github.com/helm/charts/tree/master/incubator/logstash
50logstash:
51 enabled: true
52 elasticsearch:
53 host: "logging-elasticsearch-client"
54
55 # we have kafka, so persistence isn't needed
56 # ref: https://www.elastic.co/guide/en/logstash/current/persistent-queues.html
57 persistence:
58 enabled: false
59
60 # 'config' k/v are turned into env vars for logstash container
61 # ref: https://www.elastic.co/guide/en/logstash/current/docker-config.html#docker-env-config
62 # config:
63 # LOG_LEVEL: trace
64
65 # Kafka input plugin
66 # ref: https://www.elastic.co/guide/en/logstash/current/plugins-inputs-kafka.html
67 inputs:
68 main: |-
69 input {
70 kafka {
71 bootstrap_servers => "cord-kafka:9092"
72 client_id => "logstash_ck"
73 codec => json { charset => "UTF-8" }
74 consumer_threads => 1
75 decorate_events => true
76 metadata_max_age_ms => 60000 # recheck for new topics every minute
77 topics_pattern => 'authentication.*|dhcp.*|onos.*|onu.*|xos.*'
78 type => "cord-kafka"
79 }
80 kafka {
81 bootstrap_servers => "voltha-kafka:9092"
82 client_id => "logstash_vk"
83 codec => json { charset => "UTF-8" }
84 consumer_threads => 1
85 decorate_events => true
86 metadata_max_age_ms => 60000 # recheck for new topics every minute
87 topics_pattern => 'voltha.*'
88 type => "voltha-kafka"
89 }
90 }
91
92 filters:
93 main: |-
94 filter {
95 mutate {
96 add_field => {
97 "kafka_topic" => "%{[@metadata][kafka][topic]}"
98 "kafka_timestamp" => "%{[@metadata][kafka][timestamp]}"
99 }
100 }
101
102 date {
103 match => [ "ts", "UNIX" ]
104 target => "voltha_ts"
105 tag_on_failure => []
106 }
107
108 json {
109 source => "data"
110 target => "data"
111 skip_on_invalid_json => true
112 }
113 }
114
115 outputs:
116 main: |-
117 output {
118 elasticsearch {
119 hosts => ["${ELASTICSEARCH_HOST}:${ELASTICSEARCH_PORT}"]
120 }
121 }
122
123# fluentd-elasticsearch config
124# ref: https://github.com/helm/charts/tree/master/stable/fluentd-elasticsearch
125# forwards k8s logs from nodes to elasticsearch
126fluentd-elasticsearch:
127 enabled: false
128 elasticsearch:
129 host: "logging-elasticsearch-client"
130