diff --git a/stable/yugaware/templates/statefulset.yaml b/stable/yugaware/templates/statefulset.yaml index c854aabe43..c612399629 100644 --- a/stable/yugaware/templates/statefulset.yaml +++ b/stable/yugaware/templates/statefulset.yaml @@ -71,8 +71,12 @@ spec: {{- end }} volumes: - name: yugaware-storage + {{- if .Values.yugaware.persistentVolume.enabled }} persistentVolumeClaim: claimName: {{ .Release.Name }}-yugaware-storage + {{- else }} + emptyDir: {} + {{- end }} - name: yugaware-ui emptyDir: {} - name: yugaware-config diff --git a/stable/yugaware/templates/volumes.yaml b/stable/yugaware/templates/volumes.yaml index b6c5d51c6f..1f8bf5ad34 100644 --- a/stable/yugaware/templates/volumes.yaml +++ b/stable/yugaware/templates/volumes.yaml @@ -1,3 +1,4 @@ +{{- if .Values.yugaware.persistentVolume.enabled }} --- apiVersion: v1 kind: PersistentVolumeClaim @@ -21,3 +22,4 @@ spec: resources: requests: storage: {{ .Values.yugaware.storage }} +{{- end }} diff --git a/stable/yugaware/values.yaml b/stable/yugaware/values.yaml index 41f9ec533a..f51a662b06 100644 --- a/stable/yugaware/values.yaml +++ b/stable/yugaware/values.yaml @@ -66,6 +66,9 @@ yugaware: storageClass: "" storageAnnotations: {} multiTenant: false + ## This is for testing purposes only. + persistentVolume: + enabled: true ## Name of existing ServiceAccount. When provided, the chart won't create a ServiceAccount. ## It will attach the required RBAC roles to it. ## Helpful in Yugabyte Platform GKE App.