chore: fluent-bit,fluentd chart updates

This commit is contained in:
Stefan Reimer 2021-08-27 12:14:46 +02:00
parent 68dc39b4b3
commit b2e2d12ec9
17 changed files with 172 additions and 153 deletions

View File

@ -2,7 +2,7 @@ apiVersion: v2
name: kubezero-logging name: kubezero-logging
description: KubeZero Umbrella Chart for complete EFK stack description: KubeZero Umbrella Chart for complete EFK stack
type: application type: application
version: 0.7.6 version: 0.7.7
appVersion: 1.6.0 appVersion: 1.6.0
home: https://kubezero.com home: https://kubezero.com
icon: https://cdn.zero-downtime.net/assets/kubezero/logo-small-64.png icon: https://cdn.zero-downtime.net/assets/kubezero/logo-small-64.png
@ -23,9 +23,9 @@ dependencies:
# repository: https://helm.elastic.co # repository: https://helm.elastic.co
condition: eck-operator.enabled condition: eck-operator.enabled
- name: fluentd - name: fluentd
version: 0.2.6 version: 0.2.10
condition: fluentd.enabled condition: fluentd.enabled
- name: fluent-bit - name: fluent-bit
version: 0.15.15 version: 0.16.3
condition: fluent-bit.enabled condition: fluent-bit.enabled
kubeVersion: ">= 1.18.0" kubeVersion: ">= 1.18.0"

View File

@ -1,8 +1,9 @@
annotations: annotations:
artifacthub.io/changes: | artifacthub.io/changes: |
- Upgrade fluent-bit image to v1.7.9 - kind: changed
description: Update image version to v1.8.3.
apiVersion: v1 apiVersion: v1
appVersion: 1.7.9 appVersion: 1.8.3
description: Fast and lightweight log processor and forwarder or Linux, OSX and BSD description: Fast and lightweight log processor and forwarder or Linux, OSX and BSD
family operating systems. family operating systems.
home: https://fluentbit.io/ home: https://fluentbit.io/
@ -21,4 +22,4 @@ maintainers:
name: fluent-bit name: fluent-bit
sources: sources:
- https://github.com/fluent/fluent-bit/ - https://github.com/fluent/fluent-bit/
version: 0.15.15 version: 0.16.3

View File

@ -0,0 +1 @@
logLevel: debug

View File

@ -9,6 +9,8 @@ priorityClassName: {{ .Values.priorityClassName }}
serviceAccountName: {{ include "fluent-bit.serviceAccountName" . }} serviceAccountName: {{ include "fluent-bit.serviceAccountName" . }}
securityContext: securityContext:
{{- toYaml .Values.podSecurityContext | nindent 2 }} {{- toYaml .Values.podSecurityContext | nindent 2 }}
hostNetwork: {{ .Values.hostNetwork }}
dnsPolicy: {{ .Values.dnsPolicy }}
{{- with .Values.dnsConfig }} {{- with .Values.dnsConfig }}
dnsConfig: dnsConfig:
{{- toYaml . | nindent 2 }} {{- toYaml . | nindent 2 }}
@ -21,8 +23,6 @@ hostAliases:
initContainers: initContainers:
{{- toYaml .Values.initContainers | nindent 2 }} {{- toYaml .Values.initContainers | nindent 2 }}
{{- end }} {{- end }}
hostNetwork: true
dnsPolicy: ClusterFirstWithHostNet
containers: containers:
- name: {{ .Chart.Name }} - name: {{ .Chart.Name }}
securityContext: securityContext:
@ -56,24 +56,10 @@ containers:
protocol: {{ .protocol }} protocol: {{ .protocol }}
{{- end }} {{- end }}
{{- end }} {{- end }}
{{- if .Values.livenessProbe }}
livenessProbe: livenessProbe:
{{- toYaml .Values.livenessProbe | nindent 6 }} {{- toYaml .Values.livenessProbe | nindent 6 }}
{{- else }}
livenessProbe:
httpGet:
path: /
port: http
{{- end }}
{{- if .Values.readinessProbe }}
readinessProbe: readinessProbe:
{{- toYaml .Values.readinessProbe | nindent 6 }} {{- toYaml .Values.readinessProbe | nindent 6 }}
{{- else }}
readinessProbe:
httpGet:
path: /
port: http
{{- end }}
resources: resources:
{{- toYaml .Values.resources | nindent 6 }} {{- toYaml .Values.resources | nindent 6 }}
volumeMounts: volumeMounts:

View File

@ -9,10 +9,12 @@ rules:
- apiGroups: - apiGroups:
- "" - ""
resources: resources:
- pods
- namespaces - namespaces
- pods
{{- if .Values.rbac.nodeAccess }}
- nodes - nodes
- nodes/proxy - nodes/proxy
{{- end }}
verbs: verbs:
- get - get
- list - list

View File

@ -5,6 +5,13 @@ metadata:
name: {{ include "fluent-bit.fullname" . }} name: {{ include "fluent-bit.fullname" . }}
labels: labels:
{{- include "fluent-bit.labels" . | nindent 4 }} {{- include "fluent-bit.labels" . | nindent 4 }}
{{- with .Values.labels }}
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with .Values.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
spec: spec:
selector: selector:
matchLabels: matchLabels:

View File

@ -5,6 +5,13 @@ metadata:
name: {{ include "fluent-bit.fullname" . }} name: {{ include "fluent-bit.fullname" . }}
labels: labels:
{{- include "fluent-bit.labels" . | nindent 4 }} {{- include "fluent-bit.labels" . | nindent 4 }}
{{- with .Values.labels }}
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with .Values.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
spec: spec:
replicas: {{ .Values.replicaCount }} replicas: {{ .Values.replicaCount }}
{{- with .Values.updateStrategy }} {{- with .Values.updateStrategy }}

View File

@ -17,7 +17,7 @@ spec:
- ALL - ALL
volumes: volumes:
- '*' - '*'
hostNetwork: false hostNetwork: {{ .Values.hostNetwork }}
hostIPC: false hostIPC: false
hostPID: false hostPID: false
runAsUser: runAsUser:

View File

@ -8,8 +8,9 @@ replicaCount: 1
image: image:
repository: fluent/fluent-bit repository: fluent/fluent-bit
# Overrides the image tag whose default is {{ .Chart.AppVersion }}
tag: ""
pullPolicy: Always pullPolicy: Always
# tag:
testFramework: testFramework:
enabled: false enabled: false
@ -29,99 +30,98 @@ serviceAccount:
rbac: rbac:
create: true create: true
nodeAccess: false
podSecurityPolicy: podSecurityPolicy:
create: false create: false
annotations: {} annotations: {}
podSecurityContext: podSecurityContext: {}
{} # fsGroup: 2000
# fsGroup: 2000
hostNetwork: false
dnsPolicy: ClusterFirst
dnsConfig: {} dnsConfig: {}
# nameservers: # nameservers:
# - 1.2.3.4 # - 1.2.3.4
# searches: # searches:
# - ns1.svc.cluster-domain.example # - ns1.svc.cluster-domain.example
# - my.dns.search.suffix # - my.dns.search.suffix
# options: # options:
# - name: ndots # - name: ndots
# value: "2" # value: "2"
# - name: edns0 # - name: edns0
hostAliases: [] hostAliases: []
# - ip: "1.2.3.4" # - ip: "1.2.3.4"
# hostnames: # hostnames:
# - "foo.local" # - "foo.local"
# - "bar.local" # - "bar.local"
securityContext: securityContext: {}
{} # capabilities:
# capabilities: # drop:
# drop: # - ALL
# - ALL # readOnlyRootFilesystem: true
# readOnlyRootFilesystem: true # runAsNonRoot: true
# runAsNonRoot: true # runAsUser: 1000
# runAsUser: 1000
service: service:
type: ClusterIP type: ClusterIP
port: 2020 port: 2020
labels: labels: {}
{} annotations: {}
annotations: # prometheus.io/path: "/api/v1/metrics/prometheus"
{} # prometheus.io/port: "2020"
# prometheus.io/path: "/api/v1/metrics/prometheus" # prometheus.io/scrape: "true"
# prometheus.io/port: "2020"
# prometheus.io/scrape: "true"
serviceMonitor: serviceMonitor:
enabled: false enabled: false
# namespace: monitoring # namespace: monitoring
# interval: 10s # interval: 10s
# scrapeTimeout: 10s # scrapeTimeout: 10s
# selector: # selector:
# prometheus: my-prometheus # prometheus: my-prometheus
prometheusRule: prometheusRule:
enabled: false enabled: false
# namespace: "" # namespace: ""
# additionnalLabels: {} # additionnalLabels: {}
# rules: # rules:
# - alert: NoOutputBytesProcessed # - alert: NoOutputBytesProcessed
# expr: rate(fluentbit_output_proc_bytes_total[5m]) == 0 # expr: rate(fluentbit_output_proc_bytes_total[5m]) == 0
# annotations: # annotations:
# message: | # message: |
# Fluent Bit instance {{ $labels.instance }}'s output plugin {{ $labels.name }} has not processed any # Fluent Bit instance {{ $labels.instance }}'s output plugin {{ $labels.name }} has not processed any
# bytes for at least 15 minutes. # bytes for at least 15 minutes.
# summary: No Output Bytes Processed # summary: No Output Bytes Processed
# for: 15m # for: 15m
# labels: # labels:
# severity: critical # severity: critical
dashboards: dashboards:
enabled: false enabled: false
labelKey: grafana_dashboard labelKey: grafana_dashboard
annotations: {} annotations: {}
livenessProbe:
livenessProbe: {} httpGet:
# httpGet: path: /
# path: / port: http
# port: http
readinessProbe: readinessProbe:
# httpGet: httpGet:
# path: / path: /api/v1/health
# port: http port: http
resources: resources: {}
{} # limits:
# limits: # cpu: 100m
# cpu: 100m # memory: 128Mi
# memory: 128Mi # requests:
# requests: # cpu: 100m
# cpu: 100m # memory: 128Mi
# memory: 128Mi
nodeSelector: {} nodeSelector: {}
@ -129,6 +129,10 @@ tolerations: []
affinity: {} affinity: {}
labels: {}
annotations: {}
podAnnotations: {} podAnnotations: {}
podLabels: {} podLabels: {}
@ -140,9 +144,9 @@ env: []
envFrom: [] envFrom: []
extraContainers: [] extraContainers: []
# - name: do-something # - name: do-something
# image: busybox # image: busybox
# command: ['do', 'something'] # command: ['do', 'something']
extraPorts: [] extraPorts: []
# - port: 5170 # - port: 5170
@ -155,17 +159,17 @@ extraVolumes: []
extraVolumeMounts: [] extraVolumeMounts: []
updateStrategy: {} updateStrategy: {}
# type: RollingUpdate # type: RollingUpdate
# rollingUpdate: # rollingUpdate:
# maxUnavailable: 1 # maxUnavailable: 1
# Make use of a pre-defined configmap instead of the one templated here # Make use of a pre-defined configmap instead of the one templated here
existingConfigMap: "" existingConfigMap: ""
networkPolicy: networkPolicy:
enabled: false enabled: false
# ingress: # ingress:
# from: [] # from: []
luaScripts: {} luaScripts: {}
@ -173,21 +177,22 @@ luaScripts: {}
config: config:
service: | service: |
[SERVICE] [SERVICE]
Flush 1
Daemon Off Daemon Off
Log_Level info Flush 1
Log_Level {{ .Values.logLevel }}
Parsers_File parsers.conf Parsers_File parsers.conf
Parsers_File custom_parsers.conf Parsers_File custom_parsers.conf
HTTP_Server On HTTP_Server On
HTTP_Listen 0.0.0.0 HTTP_Listen 0.0.0.0
HTTP_Port {{ .Values.service.port }} HTTP_Port {{ .Values.service.port }}
Health_Check On
## https://docs.fluentbit.io/manual/pipeline/inputs ## https://docs.fluentbit.io/manual/pipeline/inputs
inputs: | inputs: |
[INPUT] [INPUT]
Name tail Name tail
Path /var/log/containers/*.log Path /var/log/containers/*.log
Parser docker multiline.parser docker, cri
Tag kube.* Tag kube.*
Mem_Buf_Limit 5MB Mem_Buf_Limit 5MB
Skip_Long_Lines On Skip_Long_Lines On
@ -270,6 +275,8 @@ args: []
command: [] command: []
initContainers: [] initContainers: []
# - name: do-something # - name: do-something
# image: busybox # image: busybox
# command: ['do', 'something'] # command: ['do', 'something']
logLevel: info

View File

@ -6,8 +6,10 @@ icon: https://www.fluentd.org/assets/img/miscellany/fluentd-logo_2x.png
maintainers: maintainers:
- email: eduardo@treasure-data.com - email: eduardo@treasure-data.com
name: edsiper name: edsiper
- email: diogo.filipe.tomas.guerra@cern.ch
name: dioguerra
name: fluentd name: fluentd
sources: sources:
- https://github.com/fluent/fluentd/ - https://github.com/fluent/fluentd/
- https://github.com/fluent/fluentd-kubernetes-daemonset - https://github.com/fluent/fluentd-kubernetes-daemonset
version: 0.2.6 version: 0.2.10

View File

@ -5,16 +5,28 @@ metadata:
name: {{ include "fluentd.fullname" . }} name: {{ include "fluentd.fullname" . }}
labels: labels:
{{- include "fluentd.labels" . | nindent 4 }} {{- include "fluentd.labels" . | nindent 4 }}
{{- with .Values.labels }}
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with .Values.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
spec: spec:
selector: selector:
matchLabels: matchLabels:
{{- include "fluentd.selectorLabels" . | nindent 6 }} {{- include "fluentd.selectorLabels" . | nindent 6 }}
{{- with .Values.updateStrategy }}
updateStrategy:
{{- toYaml . | nindent 4 }}
{{- end }}
template: template:
metadata: metadata:
{{- with .Values.podAnnotations }}
annotations: annotations:
{{- toYaml . | nindent 8 }} checksum/config: {{ include (print $.Template.BasePath "/fluentd-configurations-cm.yaml") . | sha256sum }}
{{- end }} {{- with .Values.podAnnotations }}
{{- toYaml . | nindent 8 }}
{{- end }}
labels: labels:
{{- include "fluentd.selectorLabels" . | nindent 8 }} {{- include "fluentd.selectorLabels" . | nindent 8 }}
{{- with .Values.podLabels }} {{- with .Values.podLabels }}

View File

@ -5,8 +5,19 @@ metadata:
name: {{ include "fluentd.fullname" . }} name: {{ include "fluentd.fullname" . }}
labels: labels:
{{- include "fluentd.labels" . | nindent 4 }} {{- include "fluentd.labels" . | nindent 4 }}
{{- with .Values.labels }}
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with .Values.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
spec: spec:
replicas: {{ .Values.replicaCount }} replicas: {{ .Values.replicaCount }}
{{- with .Values.updateStrategy }}
strategy:
{{- toYaml . | nindent 4 }}
{{- end }}
selector: selector:
matchLabels: matchLabels:
{{- include "fluentd.selectorLabels" . | nindent 6 }} {{- include "fluentd.selectorLabels" . | nindent 6 }}
@ -14,9 +25,9 @@ spec:
metadata: metadata:
annotations: annotations:
checksum/config: {{ include (print $.Template.BasePath "/fluentd-configurations-cm.yaml") . | sha256sum }} checksum/config: {{ include (print $.Template.BasePath "/fluentd-configurations-cm.yaml") . | sha256sum }}
{{- with .Values.podAnnotations }} {{- with .Values.podAnnotations }}
{{- toYaml . | nindent 8 }} {{- toYaml . | nindent 8 }}
{{- end }} {{- end }}
labels: labels:
{{- include "fluentd.selectorLabels" . | nindent 8 }} {{- include "fluentd.selectorLabels" . | nindent 8 }}
{{- with .Values.podLabels }} {{- with .Values.podLabels }}

View File

@ -124,6 +124,14 @@ tolerations: []
## ##
affinity: {} affinity: {}
## Annotations to be added to fluentd DaemonSet/Deployment
##
annotations: {}
## Labels to be added to fluentd DaemonSet/Deployment
##
labels: {}
## Annotations to be added to fluentd pods ## Annotations to be added to fluentd pods
## ##
podAnnotations: {} podAnnotations: {}
@ -132,6 +140,13 @@ podAnnotations: {}
## ##
podLabels: {} podLabels: {}
## Deployment strategy / DaemonSet updateStrategy
##
updateStrategy: {}
# type: RollingUpdate
# rollingUpdate:
# maxUnavailable: 1
## Additional environment variables to set for fluentd pods ## Additional environment variables to set for fluentd pods
env: env:
- name: "FLUENTD_CONF" - name: "FLUENTD_CONF"

View File

@ -1,27 +1,3 @@
diff -tubr charts/fluent-bit/templates/_pod.tpl charts/fluent-bit.zdt/templates/_pod.tpl
--- charts/fluent-bit/templates/_pod.tpl 2021-06-22 12:25:10.000000000 +0200
+++ charts/fluent-bit.zdt/templates/_pod.tpl 2021-07-20 12:44:55.349873171 +0200
@@ -21,6 +21,8 @@
initContainers:
{{- toYaml .Values.initContainers | nindent 2 }}
{{- end }}
+hostNetwork: true
+dnsPolicy: ClusterFirstWithHostNet
containers:
- name: {{ .Chart.Name }}
securityContext:
diff -tubr charts/fluent-bit/templates/clusterrole.yaml charts/fluent-bit.zdt/templates/clusterrole.yaml
--- charts/fluent-bit/templates/clusterrole.yaml 2021-06-22 12:25:10.000000000 +0200
+++ charts/fluent-bit.zdt/templates/clusterrole.yaml 2021-07-20 12:44:29.936278716 +0200
@@ -11,6 +11,8 @@
resources:
- pods
- namespaces
+ - nodes
+ - nodes/proxy
verbs:
- get
- list
diff -tubr charts/fluent-bit/templates/tests/test-connection.yaml charts/fluent-bit.zdt/templates/tests/test-connection.yaml diff -tubr charts/fluent-bit/templates/tests/test-connection.yaml charts/fluent-bit.zdt/templates/tests/test-connection.yaml
--- charts/fluent-bit/templates/tests/test-connection.yaml 2021-06-22 12:25:10.000000000 +0200 --- charts/fluent-bit/templates/tests/test-connection.yaml 2021-06-22 12:25:10.000000000 +0200
+++ charts/fluent-bit.zdt/templates/tests/test-connection.yaml 2021-05-17 12:09:02.724057438 +0200 +++ charts/fluent-bit.zdt/templates/tests/test-connection.yaml 2021-05-17 12:09:02.724057438 +0200

View File

@ -1,17 +1,3 @@
diff -tubrN charts/fluentd/templates/deployment.yaml charts/fluentd.zdt/templates/deployment.yaml
--- charts/fluentd/templates/deployment.yaml 2021-02-12 18:13:04.000000000 +0100
+++ charts/fluentd.zdt/templates/deployment.yaml 2021-03-10 09:54:49.863586462 +0100
@@ -12,8 +12,9 @@
{{- include "fluentd.selectorLabels" . | nindent 6 }}
template:
metadata:
- {{- with .Values.podAnnotations }}
annotations:
+ checksum/config: {{ include (print $.Template.BasePath "/fluentd-configurations-cm.yaml") . | sha256sum }}
+ {{- with .Values.podAnnotations }}
{{- toYaml . | nindent 8 }}
{{- end }}
labels:
diff -tubrN charts/fluentd/templates/files.conf/systemd.yaml charts/fluentd.zdt/templates/files.conf/systemd.yaml diff -tubrN charts/fluentd/templates/files.conf/systemd.yaml charts/fluentd.zdt/templates/files.conf/systemd.yaml
--- charts/fluentd/templates/files.conf/systemd.yaml 2021-02-12 18:13:04.000000000 +0100 --- charts/fluentd/templates/files.conf/systemd.yaml 2021-02-12 18:13:04.000000000 +0100
+++ charts/fluentd.zdt/templates/files.conf/systemd.yaml 1970-01-01 01:00:00.000000000 +0100 +++ charts/fluentd.zdt/templates/files.conf/systemd.yaml 1970-01-01 01:00:00.000000000 +0100

View File

@ -1,8 +1,8 @@
#!/bin/bash #!/bin/bash
ECK_VERSION=1.6.0 ECK_VERSION=1.6.0
FLUENT_BIT_VERSION=0.15.15 FLUENT_BIT_VERSION=0.16.3
FLUENTD_VERSION=0.2.6 FLUENTD_VERSION=0.2.10
# fix ECK crds handling to adhere to proper helm v3 support which also fixes ArgoCD applying updates on upgrades # fix ECK crds handling to adhere to proper helm v3 support which also fixes ArgoCD applying updates on upgrades
helm repo list | grep elastic -qc || { helm repo add elastic https://helm.elastic.co; helm repo update; } helm repo list | grep elastic -qc || { helm repo add elastic https://helm.elastic.co; helm repo update; }

View File

@ -225,15 +225,20 @@ fluentd:
fluent-bit: fluent-bit:
enabled: false enabled: false
image: #image:
#repository: public.ecr.aws/zero-downtime/fluent-bit #repository: public.ecr.aws/zero-downtime/fluent-bit
tag: 1.8.3 #tag: 1.8.3
serviceMonitor: serviceMonitor:
enabled: false enabled: false
selector: selector:
release: metrics release: metrics
#rbac:
# nodeAccess: true
#hostNetwork: true
#dnsPolicy: ClusterFirstWithHostNet
tolerations: tolerations:
- key: node-role.kubernetes.io/master - key: node-role.kubernetes.io/master
effect: NoSchedule effect: NoSchedule
@ -274,6 +279,7 @@ fluent-bit:
HTTP_Server On HTTP_Server On
HTTP_Listen 0.0.0.0 HTTP_Listen 0.0.0.0
HTTP_Port {{ .Values.service.port }} HTTP_Port {{ .Values.service.port }}
Health_Check On
inputs: | inputs: |
[INPUT] [INPUT]
Name tail Name tail