[COMMON] Allow to use ' in mariadb-init 85/109785/1
authorKrzysztof Opasiak <k.opasiak@samsung.com>
Thu, 2 Jul 2020 18:10:04 +0000 (20:10 +0200)
committerKrzysztof Opasiak <k.opasiak@samsung.com>
Thu, 2 Jul 2020 18:10:04 +0000 (20:10 +0200)
commitc5dac87fa301247928211d5944be22ae14bcd534
treef7278dd7b66a45ddd932332c80efc5adc4b40f3d
parentcc39379f8a7e42d122225af8fd7425a2a3b5325c
[COMMON] Allow to use ' in mariadb-init

' is one of characters that are placed in passwords by our default
password generation algorith. As ' is a special character in SQL
we need to escape it before concatenating it with SQL command.

Let's also add set -e to fail if any of databases has not been created

Issue-ID: OOM-2436
Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com>
Change-Id: Ida8c75639eaa4049e3f874d30666f1fe4dc02e12
kubernetes/common/mariadb-init/resources/config/db_init.sh