diff options
author | Krzysztof Opasiak <k.opasiak@samsung.com> | 2020-04-23 00:11:44 +0200 |
---|---|---|
committer | Krzysztof Opasiak <k.opasiak@samsung.com> | 2020-04-27 20:50:52 +0200 |
commit | f5e74e506c8ae56f4a7af7dfa516c5733fadb22e (patch) | |
tree | f66b73376e4102f210e6fd6099342e6c6be5d9c8 /kubernetes/common/mariadb-galera/templates/statefulset.yaml | |
parent | f69c491ed06b017fe439ff8ff48ac896e93d0f52 (diff) |
[COMMON] Allow to use ' in mysql passwords
derivePassword which we use to generate our passwords includes ' in
set of special characters that can be used in passwords.
Current implementation of bitnami configure-mysql.sh simply
concatenates password surrounded with '' rest of SQL query. This
causes issues if password contains ' as it creates invalid SQL statement.
To fix this issue we just patch the script and escape the special '
character in password.
Issue-ID: OOM-2246
Reported-by: Mateusz Pilat <m.pilat@partner.samsung.com>
Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com>
Change-Id: I3d2150760755e55558e2045cbb7ca5693c8ab71f
Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com>
Diffstat (limited to 'kubernetes/common/mariadb-galera/templates/statefulset.yaml')
-rw-r--r-- | kubernetes/common/mariadb-galera/templates/statefulset.yaml | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/kubernetes/common/mariadb-galera/templates/statefulset.yaml b/kubernetes/common/mariadb-galera/templates/statefulset.yaml index 7157e3390b..855d50e5ea 100644 --- a/kubernetes/common/mariadb-galera/templates/statefulset.yaml +++ b/kubernetes/common/mariadb-galera/templates/statefulset.yaml @@ -47,6 +47,10 @@ spec: configMap: name: {{ include "common.fullname" . }}-external-config {{- end}} + - name: init-script + configMap: + name: {{ include "common.fullname" . }} + defaultMode: 0755 - name: localtime hostPath: path: /etc/localtime @@ -104,6 +108,9 @@ spec: - mountPath: /etc/localtime name: localtime readOnly: true + - mountPath: /usr/share/container-scripts/mysql/configure-mysql.sh + subPath: configure-mysql.sh + name: init-script {{- if .Values.persistence.enabled }} - mountPath: /var/lib/mysql name: {{ include "common.fullname" . }}-data |