Skip to content

Commit 909c9b8

Browse files
committed
[mariadb][backup-v2] use granular backup/restore permissions
* remove unneeded privileges from the `backup` user * `maria-back-me-up` updated to `10.11-20260401120352`
1 parent 4aeb63e commit 909c9b8

File tree

3 files changed

+29
-3
lines changed

3 files changed

+29
-3
lines changed

common/mariadb/CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
# Changelog
22

3+
## v0.34.0 - 2026/04/01
4+
* remove unneeded privileges from the `backup` user
5+
* `maria-back-me-up` updated to `10.11-20260401120352`
6+
* chart version bumped
7+
38
## v0.33.1 - 2026/03/27
49
* updated sidecar image:
510
* `mysqld-exporter` image updated to `0.19.0`

common/mariadb/Chart.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
apiVersion: v2
33
description: A Helm chart for Kubernetes
44
name: mariadb
5-
version: 0.33.1
5+
version: 0.34.0
66
# scripts/docker-entyrpoint.sh should be updated when appVersion is updated
77
appVersion: 10.11.16
88
dependencies:

common/mariadb/values.yaml

Lines changed: 23 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,28 @@ users:
4949
limits:
5050
max_user_connections: 4
5151
grants:
52-
- ALL PRIVILEGES ON *.*
52+
# backup & restore
53+
- SELECT ON *.*
54+
- SHOW VIEW ON *.*
55+
- TRIGGER ON *.*
56+
- LOCK TABLES ON *.*
57+
# backup only
58+
- PROCESS ON *.*
59+
- RELOAD ON *.*
60+
- REPLICATION SLAVE ON *.* # BinlogSyncer streams binlogs as a replica
61+
- BINLOG MONITOR ON *.* # --master-data=1 (SHOW MASTER STATUS)
62+
- BINLOG ADMIN ON *.* # PURGE BINARY LOGS
63+
# restore only
64+
- INSERT ON *.*
65+
- CREATE ON *.*
66+
- DROP ON *.*
67+
- ALTER ON *.*
68+
- INDEX ON *.*
69+
- REFERENCES ON *.*
70+
- CREATE VIEW ON *.*
71+
- SHUTDOWN ON *.*
72+
- REPLICATION SLAVE ADMIN ON *.* # CHANGE MASTER TO, RESET SLAVE
73+
- SET USER ON *.* # DEFINER= clauses (mysql.user view)
5374
# example:
5475
# name: example1 # This looks repetitive, but the point is that they key is the name
5576
# # you refer to in your charts, while the field 'name' is the actual name
@@ -202,7 +223,7 @@ backup_v2:
202223
enabled: false
203224
backup_dir: "./backup"
204225
image: maria-back-me-up
205-
image_version: "20260210150801"
226+
image_version: "10.11-20260401120352"
206227
full_backup_cron_schedule: "0 0 * * *"
207228
incremental_backup_in_minutes: 5
208229
purge_binlog_after_minutes: 60

0 commit comments

Comments
 (0)