diff --git a/cluster/addons/fluentd-elasticsearch/fluentd-es-configmap.yaml b/cluster/addons/fluentd-elasticsearch/fluentd-es-configmap.yaml index 656c92d3848a..d6b74199a8a9 100644 --- a/cluster/addons/fluentd-elasticsearch/fluentd-es-configmap.yaml +++ b/cluster/addons/fluentd-elasticsearch/fluentd-es-configmap.yaml @@ -1,7 +1,7 @@ kind: ConfigMap apiVersion: v1 metadata: - name: fluentd-es-config-v0.1.7 + name: fluentd-es-config-v0.2.0 namespace: kube-system labels: addonmanager.kubernetes.io/mode: Reconcile @@ -143,6 +143,39 @@ data: max_lines 1000 + # Concatenate multi-line logs + + @id filter_concat + @type concat + key message + multiline_end_regexp /\n$/ + separator "" + + + # Enriches records with Kubernetes metadata + + @id filter_kubernetes_metadata + @type kubernetes_metadata + + + # Fixes json fields in Elasticsearch + + @id filter_parser + @type parser + key_name log + reserve_data true + remove_key_name_field true + + @type multi_format + + format json + + + format none + + + + system.input.conf: |- # Example: # 2015-12-21 23:17:22,066 [salt.state ][INFO ] Completed state [net.ipv4.ip_forward] at time 23:17:22.066081 @@ -376,6 +409,7 @@ data: forward.input.conf: |- # Takes the messages sent over TCP + @id forward @type forward @@ -383,15 +417,18 @@ data: # Prometheus Exporter Plugin # input plugin that exports metrics + @id prometheus @type prometheus + @id monitor_agent @type monitor_agent # input plugin that collects metrics from MonitorAgent + @id prometheus_monitor @type prometheus_monitor host ${hostname} @@ -400,6 +437,7 @@ data: # input plugin that collects metrics for output plugin + @id prometheus_output_monitor @type prometheus_output_monitor host ${hostname} @@ -408,6 +446,7 @@ data: # input plugin that collects metrics for in_tail plugin + @id prometheus_tail_monitor @type prometheus_tail_monitor host ${hostname} @@ -415,24 +454,6 @@ data: output.conf: |- - # Enriches records with Kubernetes metadata - - @type kubernetes_metadata - - - # Adds the json parsing which was removed in kubernetes_metadata filter > 2.1.x - - @type parse_json_field - - - # Concatenate multi-line logs - - @type concat - key message - multiline_end_regexp /\n$/ - separator "" - - @id elasticsearch @type elasticsearch diff --git a/cluster/addons/fluentd-elasticsearch/fluentd-es-ds.yaml b/cluster/addons/fluentd-elasticsearch/fluentd-es-ds.yaml index dbf9b92081d9..c3df2ac253dd 100644 --- a/cluster/addons/fluentd-elasticsearch/fluentd-es-ds.yaml +++ b/cluster/addons/fluentd-elasticsearch/fluentd-es-ds.yaml @@ -107,4 +107,4 @@ spec: path: /var/lib/docker/containers - name: config-volume configMap: - name: fluentd-es-config-v0.1.7 + name: fluentd-es-config-v0.2.0 diff --git a/cluster/addons/fluentd-elasticsearch/fluentd-es-image/Dockerfile b/cluster/addons/fluentd-elasticsearch/fluentd-es-image/Dockerfile index 408e49628249..650966a8529f 100644 --- a/cluster/addons/fluentd-elasticsearch/fluentd-es-image/Dockerfile +++ b/cluster/addons/fluentd-elasticsearch/fluentd-es-image/Dockerfile @@ -39,7 +39,6 @@ RUN BUILD_DEPS="make gcc g++ libc6-dev ruby-dev libffi-dev curl" \ && echo 'gem: --no-document' >> /etc/gemrc \ && gem install --file Gemfile \ && mkdir -p /etc/fluent/plugin \ - && curl -s https://raw.githubusercontent.com/openshift/origin-aggregated-logging/master/fluentd/lib/filter_parse_json_field/lib/filter_parse_json_field.rb -o /etc/fluent/plugin/filter_parse_json_field.rb \ && apt-get purge -y --auto-remove \ -o APT::AutoRemove::RecommendsImportant=false \ $BUILD_DEPS \