X-Git-Url: https://gerrit.onap.org/r/gitweb?a=blobdiff_plain;f=kubernetes%2Fcommon%2Fcommon%2Ftemplates%2F_log.tpl;h=993c48239a247ce29003d41fb920f1b151362186;hb=refs%2Fheads%2Fmaster;hp=dc714aecc4017f0eba73cd0cea7325fe2bccd567;hpb=54fcf96c94b00006895ccb074cc8aa68867194e5;p=oom.git diff --git a/kubernetes/common/common/templates/_log.tpl b/kubernetes/common/common/templates/_log.tpl index dc714aecc4..ca5eb11992 100644 --- a/kubernetes/common/common/templates/_log.tpl +++ b/kubernetes/common/common/templates/_log.tpl @@ -1,5 +1,6 @@ {{/* # Copyright © 2020 Orange +# Modification Copyright © 2025 Deutsche Telekom # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -23,20 +24,33 @@ - name: filebeat-conf mountPath: /usr/share/filebeat/filebeat.yml subPath: filebeat.yml - - name: logs + - name: sidecar-logs mountPath: {{ .Values.log.path }} - name: filebeat-data mountPath: /usr/share/filebeat/data + resources: + requests: + cpu: "10m" + memory: "5Mi" + limits: + cpu: "100m" + memory: "20Mi" {{- end -}} {{- end -}} {{- define "common.log.volumes" -}} -{{- if .Values.global.centralizedLoggingEnabled }} +{{- $dot := default . .dot }} +{{- if $dot.Values.global.centralizedLoggingEnabled }} +{{- $configMapName := printf "%s-filebeat" (default (include "common.fullname" $dot) .configMapNamePrefix) }} - name: filebeat-conf configMap: - name: {{ include "common.fullname" . }}-filebeat + name: {{ $configMapName }} - name: filebeat-data - emptyDir: {} + emptyDir: + sizeLimit: {{ $dot.Values.log.dataSizeLimit }} +- name: sidecar-logs + emptyDir: + sizeLimit: {{ $dot.Values.log.sizeLimit }} {{- end -}} {{- end -}} @@ -50,4 +64,3 @@ data: {{ tpl (.Files.Glob "resources/config/log/filebeat/*").AsConfig . | indent 2 }} {{- end }} {{- end -}} -