Skip to content

Commit

Permalink
fix: add apiVersion and kind to PersistentVolumeClaims
Browse files Browse the repository at this point in the history
  • Loading branch information
aqeelat committed Sep 8, 2024
1 parent 7d06347 commit dfde2e2
Show file tree
Hide file tree
Showing 12 changed files with 60 additions and 36 deletions.
40 changes: 21 additions & 19 deletions charts/camunda-platform-8.2/charts/zeebe/templates/statefulset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -208,23 +208,25 @@ spec:

{{- if eq .Values.persistenceType "disk" }}
volumeClaimTemplates:
- metadata:
name: data
spec:
accessModes: {{ .Values.pvcAccessModes }}
{{- if .Values.pvcStorageClassName }}
{{- if (eq "-" .Values.pvcStorageClassName) }}
storageClassName: ""
{{- else }}
storageClassName: {{ .Values.pvcStorageClassName }}
{{- end }}
{{- end }}
{{- if .Values.pvcSelector }}
{{- with .Values.pvcSelector }}
selector: {{ toYaml . | nindent 10 }}
{{- end }}
{{- end }}
resources:
requests:
storage: {{ .Values.pvcSize | quote }}
- apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: data
spec:
accessModes: {{ .Values.pvcAccessModes }}
{{- if .Values.pvcStorageClassName }}
{{- if (eq "-" .Values.pvcStorageClassName) }}
storageClassName: ""
{{- else }}
storageClassName: {{ .Values.pvcStorageClassName }}
{{- end }}
{{- end }}
{{- if .Values.pvcSelector }}
{{- with .Values.pvcSelector }}
selector: {{ toYaml . | nindent 10 }}
{{- end }}
{{- end }}
resources:
requests:
storage: {{ .Values.pvcSize | quote }}
{{- end }}
Original file line number Diff line number Diff line change
Expand Up @@ -158,10 +158,12 @@ spec:
- zeebe-broker
topologyKey: kubernetes.io/hostname
volumeClaimTemplates:
- metadata:
name: data
spec:
accessModes: [ReadWriteOnce]
resources:
requests:
storage: "32Gi"
- apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: data
spec:
accessModes: [ReadWriteOnce]
resources:
requests:
storage: "32Gi"
4 changes: 3 additions & 1 deletion charts/camunda-platform-8.3/templates/zeebe/statefulset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,9 @@ spec:

{{- if eq .Values.zeebe.persistenceType "disk" }}
volumeClaimTemplates:
- metadata:
- apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: data
spec:
accessModes: {{ .Values.zeebe.pvcAccessModes }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,9 @@ spec:
topologyKey: kubernetes.io/hostname
# yamllint enable
volumeClaimTemplates:
- metadata:
- apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: data
spec:
accessModes: [ReadWriteOnce]
Expand Down
4 changes: 3 additions & 1 deletion charts/camunda-platform-8.4/templates/zeebe/statefulset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,9 @@ spec:

{{- if eq .Values.zeebe.persistenceType "disk" }}
volumeClaimTemplates:
- metadata:
- apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: data
annotations:
{{- toYaml .Values.zeebe.pvcAnnotations | nindent 10 }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,9 @@ spec:
topologyKey: kubernetes.io/hostname
# yamllint enable
volumeClaimTemplates:
- metadata:
- apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: data
annotations:
{}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -273,7 +273,9 @@ spec:

{{- if eq .Values.zeebe.persistenceType "disk" }}
volumeClaimTemplates:
- metadata:
- apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: data
annotations:
{{- toYaml .Values.zeebe.pvcAnnotations | nindent 10 }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,9 @@ spec:
topologyKey: kubernetes.io/hostname
# yamllint enable
volumeClaimTemplates:
- metadata:
- apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: data
annotations:
{}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,9 @@ spec:

{{- if eq .Values.zeebe.persistenceType "disk" }}
volumeClaimTemplates:
- metadata:
- apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: data
annotations:
{{- toYaml .Values.zeebe.pvcAnnotations | nindent 10 }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,9 @@ spec:
topologyKey: kubernetes.io/hostname
# yamllint enable
volumeClaimTemplates:
- metadata:
- apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: data
annotations:
{}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -608,7 +608,9 @@ spec:
emptyDir: {}
{{- else }}
volumeClaimTemplates:
- metadata:
- apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: data
{{- if .Values.primary.persistence.annotations }}
annotations: {{- include "common.tplvalues.render" (dict "value" .Values.primary.persistence.annotations "context" $) | nindent 10 }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -504,7 +504,9 @@ spec:
emptyDir: {}
{{- else }}
volumeClaimTemplates:
- metadata:
- apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: data
{{- if .Values.readReplicas.persistence.annotations }}
annotations: {{- include "common.tplvalues.render" (dict "value" .Values.readReplicas.persistence.annotations "context" $) | nindent 10 }}
Expand Down

0 comments on commit dfde2e2

Please sign in to comment.