summaryrefslogtreecommitdiffstats
path: root/kubernetes
diff options
context:
space:
mode:
authorGuillaume Lambert <guillaume.lambert@orange.com>2021-03-12 10:59:34 +0100
committerKrzysztof Opasiak <k.opasiak@samsung.com>2021-09-07 07:22:20 +0000
commita8f89adf23312cd9207f01ebdace6ea99a9e35d7 (patch)
tree8800a1346fb0bdffde39a91f41cb1b9c35ac42ea /kubernetes
parent0b7eb9ac71bf40746566b0dd48ddfca56b3dc2aa (diff)
[COMMON] Fix ${p//pat/str} bashism
pointed out by checkbashisms Issue-ID: OOM-2643 Signed-off-by: Guillaume Lambert <guillaume.lambert@orange.com> Change-Id: Ic3162f08f39026bf15a2c5a990b0078635c1c918
Diffstat (limited to 'kubernetes')
-rw-r--r--kubernetes/portal/components/portal-mariadb/resources/config/mariadb/docker-entrypoint.sh4
1 files changed, 2 insertions, 2 deletions
diff --git a/kubernetes/portal/components/portal-mariadb/resources/config/mariadb/docker-entrypoint.sh b/kubernetes/portal/components/portal-mariadb/resources/config/mariadb/docker-entrypoint.sh
index b416fdd5d8..0247ad6125 100644
--- a/kubernetes/portal/components/portal-mariadb/resources/config/mariadb/docker-entrypoint.sh
+++ b/kubernetes/portal/components/portal-mariadb/resources/config/mariadb/docker-entrypoint.sh
@@ -278,10 +278,10 @@ docker_setup_db() {
if [ -n "$MYSQL_DATABASE" ]; then
mysql_note "Giving user ${MYSQL_USER} access to schema ${MYSQL_DATABASE}"
- echo "GRANT ALL ON \`${MYSQL_DATABASE//_/\\_}\`.* TO '$MYSQL_USER'@'%' ;" |docker_process_sql --database=mysql
+ echo "GRANT ALL ON \`$(echo $MYSQL_DATABASE | sed 's@_@\\_@g')\`.* TO '$MYSQL_USER'@'%' ;" | docker_process_sql --database=mysql
fi
- echo "FLUSH PRIVILEGES ;" |docker_process_sql --database=mysql
+ echo "FLUSH PRIVILEGES ;" | docker_process_sql --database=mysql
fi
}