# limitations under the License.
*/}}
+{{- if and .Values.backup.enabled .Values.global.mariadbGalera.useOperator }}
+{{ include "common.mariadbOpBackup" . }}
+{{ else }}
{{- if and .Values.backup.enabled .Values.persistence.enabled }}
apiVersion: batch/v1beta1
kind: CronJob
jobTemplate:
spec:
template:
+ metadata:
+ annotations:
+ # Workarround to exclude K8S API from istio communication
+ # as init-container (readinessCheck) does not work with the
+ # Istio CNI plugin, see:
+ # (https://istio.io/latest/docs/setup/additional-setup/cni/#compatibility-with-application-init-containers)
+ traffic.sidecar.istio.io/excludeOutboundPorts: "443"
spec:
serviceAccountName: {{ include "common.fullname" (dict "suffix" "read" "dot" . )}}
{{ include "common.podSecurityContext" . | indent 10 | trim}}
name: tmp-data
- mountPath: /opt/bitnami/mariadb/tmp
name: tmp
- - mountPath: /etc/localtime
- name: localtime
- readOnly: true
- name: backup-dir
mountPath: /backup
- imagePullSecrets:
- - name: {{ include "common.namespace" . }}-docker-registry-key
+ {{- include "common.imagePullSecrets" . | nindent 10 }}
volumes:
- - name: localtime
- hostPath:
- path: /etc/localtime
- name: data
persistentVolumeClaim:
{{- if .Values.persistence.existingClaim }}
- name: tmp
emptyDir: {}
{{- end }}
+{{- end }}