mirror of
https://github.com/bitnami/charts.git
synced 2026-02-20 20:17:21 +08:00
[bitnami/thanos] feat: Option to enable ephemeral persistent volume for compactor (#22808)
Signed-off-by: Martin Balint <martin.balint@threatmark.com> Co-authored-by: Martin Balint <martin.balint@threatmark.com>
This commit is contained in:
@@ -35,4 +35,4 @@ maintainers:
|
||||
name: thanos
|
||||
sources:
|
||||
- https://github.com/bitnami/charts/tree/main/bitnami/thanos
|
||||
version: 12.22.1
|
||||
version: 12.23.0
|
||||
|
||||
@@ -653,6 +653,7 @@ Check the section [Integrate Thanos with Prometheus and Alertmanager](#integrate
|
||||
| `compactor.ingress.path` | Ingress path | `/` |
|
||||
| `compactor.ingress.pathType` | Ingress path type | `ImplementationSpecific` |
|
||||
| `compactor.persistence.enabled` | Enable data persistence using PVC(s) on Thanos Compactor pods | `true` |
|
||||
| `compactor.persistence.ephemeral` | Use ephemeral volume for data persistence using PVC(s) on Thanos Compactor pods | `false` |
|
||||
| `compactor.persistence.defaultEmptyDir` | Defaults to emptyDir if persistence is disabled. | `true` |
|
||||
| `compactor.persistence.storageClass` | Specify the `storageClass` used to provision the volume | `""` |
|
||||
| `compactor.persistence.accessModes` | PVC Access Modes for data volume | `["ReadWriteOnce"]` |
|
||||
|
||||
@@ -223,8 +223,30 @@ spec:
|
||||
{{- if or .Values.compactor.persistence.enabled .Values.compactor.persistence.defaultEmptyDir }}
|
||||
- name: data
|
||||
{{- if .Values.compactor.persistence.enabled }}
|
||||
{{- if .Values.compactor.persistence.ephemeral }}
|
||||
ephemeral:
|
||||
volumeClaimTemplate:
|
||||
metadata:
|
||||
{{- $labels := include "common.tplvalues.merge" ( dict "values" ( list .Values.compactor.persistence.labels .Values.commonLabels ) "context" . ) }}
|
||||
labels: {{- include "common.labels.standard" ( dict "customLabels" $labels "context" $ ) | nindent 14 }}
|
||||
app.kubernetes.io/component: compactor
|
||||
{{- if or .Values.compactor.persistence.annotations .Values.commonAnnotations }}
|
||||
{{- $annotations := include "common.tplvalues.merge" ( dict "values" ( list .Values.compactor.persistence.annotations .Values.commonAnnotations ) "context" . ) }}
|
||||
annotations: {{- include "common.tplvalues.render" ( dict "value" $annotations "context" $) | nindent 14 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
accessModes:
|
||||
{{- range .Values.compactor.persistence.accessModes }}
|
||||
- {{ . | quote }}
|
||||
{{- end }}
|
||||
{{- include "common.storage.class" (dict "persistence" .Values.compactor.persistence "global" .Values.global) | nindent 12 }}
|
||||
resources:
|
||||
requests:
|
||||
storage: {{ .Values.compactor.persistence.size | quote }}
|
||||
{{- else }}
|
||||
persistentVolumeClaim:
|
||||
claimName: {{ include "thanos.compactor.pvcName" . }}
|
||||
{{- end }}
|
||||
{{- else }}
|
||||
emptyDir: {}
|
||||
{{- end }}
|
||||
|
||||
@@ -3,7 +3,7 @@ Copyright VMware, Inc.
|
||||
SPDX-License-Identifier: APACHE-2.0
|
||||
*/}}
|
||||
|
||||
{{- if and .Values.compactor.persistence.enabled (not .Values.compactor.persistence.existingClaim) .Values.compactor.enabled }}
|
||||
{{- if and .Values.compactor.persistence.enabled (not (or .Values.compactor.persistence.existingClaim .Values.compactor.persistence.ephemeral)) .Values.compactor.enabled }}
|
||||
kind: PersistentVolumeClaim
|
||||
apiVersion: v1
|
||||
metadata:
|
||||
|
||||
@@ -2222,6 +2222,9 @@ compactor:
|
||||
## @param compactor.persistence.enabled Enable data persistence using PVC(s) on Thanos Compactor pods
|
||||
##
|
||||
enabled: true
|
||||
## @param compactor.persistence.ephemeral Use ephemeral volume for data persistence using PVC(s) on Thanos Compactor pods
|
||||
##
|
||||
ephemeral: false
|
||||
## @param compactor.persistence.defaultEmptyDir Defaults to emptyDir if persistence is disabled.
|
||||
##
|
||||
defaultEmptyDir: true
|
||||
|
||||
Reference in New Issue
Block a user