Skip to content

Commit 4cc7ad2

Browse files
author
Simon Emms
committed
[installer]: configure kots to backup in-cluster mysql
1 parent 1613e01 commit 4cc7ad2

File tree

1 file changed

+14
-1
lines changed

1 file changed

+14
-1
lines changed

install/installer/third_party/charts/mysql/values.yaml

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,19 @@ mysql:
88
# We switched to the specific version because "5.7" was broken at least once
99
tag: 5.7.34-debian-10-r55
1010
primary:
11+
# Backup settings
12+
podAnnotations:
13+
backup.velero.io/backup-volumes: backup
14+
pre.hook.backup.velero.io/command: |
15+
["/bin/bash", "-c", "mysqldump -u root -p$MYSQL_ROOT_PASSWORD --databases $MYSQL_DATABASE gitpod-sessions -h 127.0.0.1 > /backup/mysqldump.sql"]
16+
pre.hook.backup.velero.io/timeout: 5m
17+
extraVolumes:
18+
- name: backup
19+
emptyDir: {}
20+
extraVolumeMounts:
21+
- name: backup
22+
mountPath: /backup
23+
# End of backup settings
1124
extraEnvVars:
1225
# We rely on this in our DB implementations: NULL (re-)sets configured columns to be initialized with CURRENT_TIMESTAMP.
1326
# OFF is the default as documented [here](https://dev.mysql.com/doc/refman/5.7/en/server-system-variables.html#sysvar_explicit_defaults_for_timestamp) (we also see this in GCP), but not for this chart.
@@ -19,4 +32,4 @@ mysql:
1932
serviceAccount:
2033
create: false
2134
volumePermissions:
22-
enabled: true
35+
enabled: true

0 commit comments

Comments
 (0)