From e5a4d4c413398d8149b1fc7fe8e88eec422f9227 Mon Sep 17 00:00:00 2001 From: Sebastian Brandt Date: Tue, 28 Jul 2020 22:20:27 +0200 Subject: [PATCH] chore: fluent-bit update 1.5.2 (#375) --- addons/fluentbit/1.5.x/fluentbit-2.yaml | 192 ++++++++++++++++++++++++ 1 file changed, 192 insertions(+) create mode 100644 addons/fluentbit/1.5.x/fluentbit-2.yaml diff --git a/addons/fluentbit/1.5.x/fluentbit-2.yaml b/addons/fluentbit/1.5.x/fluentbit-2.yaml new file mode 100644 index 00000000..5e1d0252 --- /dev/null +++ b/addons/fluentbit/1.5.x/fluentbit-2.yaml @@ -0,0 +1,192 @@ +--- +apiVersion: kubeaddons.mesosphere.io/v1beta1 +kind: Addon +metadata: + name: fluentbit + namespace: kubeaddons + labels: + kubeaddons.mesosphere.io/name: fluentbit + annotations: + catalog.kubeaddons.mesosphere.io/addon-revision: "1.5.2-2" + appversion.kubeaddons.mesosphere.io/fluentbit: "1.5.2" + values.chart.helm.kubeaddons.mesosphere.io/fluentbit: "https://raw.githubusercontent.com/fluent/helm-charts/6cba78c/charts/fluent-bit/values.yaml" +spec: + kubernetes: + minSupportedVersion: v1.15.6 + requires: + # This allows us to have fluentbit wait until ES is deployed and has the right configurations up, in particular + # setting up index templates + - matchLabels: + kubeaddons.mesosphere.io/name: elasticsearch + cloudProvider: + - name: aws + enabled: true + - name: azure + enabled: true + - name: gcp + enabled: true + - name: docker + enabled: false + - name: none + enabled: true + chartReference: + chart: fluent-bit + repo: https://fluent.github.io/helm-charts + version: 0.6.1 + values: | + service: + annotations: + prometheus.io/path: "/api/v1/metrics/prometheus" + prometheus.io/port: "2020" + prometheus.io/scrape: "true" + tolerations: + - operator: Exists + effect: NoSchedule + - operator: Exists + effect: NoExecute + - operator: Exists + key: CriticalAddonsOnly + resources: + limits: + memory: 750Mi + requests: + cpu: 350m + memory: 350Mi + priorityClassName: system-node-critical + podSecurityContext: + privileged: true + extraVolumes: + - name: tail-db + emptyDir: {} + # we create this to get rid of error messages that would appear on non control-plane nodes + - name: kubernetes-audit + hostPath: + path: /var/log/kubernetes/audit + type: DirectoryOrCreate + # needed for kmsg input plugin + - name: uptime + hostPath: + path: /proc/uptime + type: File + - name: kmsg + hostPath: + path: /dev/kmsg + type: CharDevice + extraVolumeMounts: + - name: tail-db + mountPath: /tail-db + - name: kubernetes-audit + mountPath: /var/log/kubernetes/audit + - name: uptime + mountPath: /proc/uptime + - name: kmsg + mountPath: /dev/kmsg + config: + ## https://docs.fluentbit.io/manual/service + service: | + [SERVICE] + Flush 1 + Daemon Off + Log_Level error + Parsers_File parsers.conf + Parsers_File custom_parsers.conf + HTTP_Server On + HTTP_Listen 0.0.0.0 + HTTP_Port 2020 + + ## https://docs.fluentbit.io/manual/pipeline/inputs + inputs: | + [INPUT] + Name tail + Path /var/log/kubernetes/audit/*.log + Parser kubernetes-audit + DB /tail-db/audit.db + Tag audit.* + Refresh_Interval 5 + Mem_Buf_Limit 135MB + Buffer_Chunk_Size 5MB + Buffer_Max_Size 20MB + Skip_Long_Lines Off + Key kubernetes-audit + [INPUT] + Name tail + Path /var/log/containers/*.log + Parser cri + DB /tail-db/kube.db + Tag kube.* + Refresh_Interval 5 + Mem_Buf_Limit 5MB + Skip_Long_Lines On + [INPUT] + Name systemd + DB /tail-db/journal.db + Tag host.* + Max_Entries 1000 + Read_From_Tail On + Strip_Underscores On + [INPUT] + Name kmsg + Tag kernel + + ## https://docs.fluentbit.io/manual/pipeline/filters + filters: | + [FILTER] + Name kubernetes + Match kube.* + Merge_Log On + Merge_Log_Key log_processed + Keep_Log Off + K8S-Logging.Parser On + K8S-Logging.Exclude On + + ## https://docs.fluentbit.io/manual/pipeline/outputs + outputs: | + [OUTPUT] + Name es + Match audit.* + Host elasticsearch-kubeaddons-client.kubeaddons.svc.cluster.local. + Port 9200 + Time_Key @ts + Logstash_Format On + Logstash_Prefix kubernetes_audit + Retry_Limit False + Buffer_Size 512KB + [OUTPUT] + Name es + Match kube.* + Host elasticsearch-kubeaddons-client.kubeaddons.svc.cluster.local. + Port 9200 + Time_Key @ts + Logstash_Format On + Logstash_Prefix kubernetes_cluster + Retry_Limit False + Buffer_Size 512KB + [OUTPUT] + Name es + Match host.* + Host elasticsearch-kubeaddons-client.kubeaddons.svc.cluster.local. + Port 9200 + Time_Key @ts + Logstash_Format On + Logstash_Prefix kubernetes_host + Retry_Limit False + Buffer_Size 512KB + [OUTPUT] + Name es + Match kernel + Host elasticsearch-kubeaddons-client.kubeaddons.svc.cluster.local. + Port 9200 + Time_Key @ts + Logstash_Format On + Logstash_Prefix kubernetes_host_kernel + Retry_Limit False + Buffer_Size 512KB + + ## https://docs.fluentbit.io/manual/pipeline/parsers + customParsers: | + [PARSER] + Name kubernetes-audit + Format json + Time_Keep On + Time_Key requestReceivedTimestamp + Time_Format %Y-%m-%dT%H:%M:%S.%L