Code Review
/
oom.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
[MARIADB][COMMON] Add support for mariadb-operator
[oom.git]
/
kubernetes
/
common
/
mariadb-galera
/
templates
/
backup
/
cronjob.yaml
diff --git
a/kubernetes/common/mariadb-galera/templates/backup/cronjob.yaml
b/kubernetes/common/mariadb-galera/templates/backup/cronjob.yaml
index
4248cfe
..
4548626
100644
(file)
--- a/
kubernetes/common/mariadb-galera/templates/backup/cronjob.yaml
+++ b/
kubernetes/common/mariadb-galera/templates/backup/cronjob.yaml
@@
-15,6
+15,9
@@
# limitations under the License.
*/}}
# 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
{{- if and .Values.backup.enabled .Values.persistence.enabled }}
apiVersion: batch/v1beta1
kind: CronJob
@@
-77,7
+80,7
@@
spec:
env:
- name: DB_PASS
{{- include "common.secret.envFromSecretFast" (dict "global" . "uid" (include "common.mariadb.secret.rootPassUID" .) "key" "password") | indent 18 }}
env:
- name: DB_PASS
{{- include "common.secret.envFromSecretFast" (dict "global" . "uid" (include "common.mariadb.secret.rootPassUID" .) "key" "password") | indent 18 }}
- resources: {{ include "common.resources" . | nindent 1
2
}}
+ resources: {{ include "common.resources" . | nindent 1
6
}}
volumeMounts:
- name: backup-dir
mountPath: /backup
volumeMounts:
- name: backup-dir
mountPath: /backup
@@
-148,7
+151,7
@@
spec:
ls -tr | grep backup | head -$filestoDelete | xargs rm -rf
fi
fi
ls -tr | grep backup | head -$filestoDelete | xargs rm -rf
fi
fi
- resources: {{ include "common.resources" . | nindent 1
2
}}
+ resources: {{ include "common.resources" . | nindent 1
6
}}
volumeMounts:
- mountPath: /bitnami/mariadb/data
name: tmp-data
volumeMounts:
- mountPath: /bitnami/mariadb/data
name: tmp-data
@@
-180,3
+183,4
@@
spec:
- name: tmp
emptyDir: {}
{{- end }}
- name: tmp
emptyDir: {}
{{- end }}
+{{- end }}