mysql : security fix root default password
This commit is contained in:
parent
81c1486c58
commit
20004ea1be
Binary file not shown.
|
@ -11,7 +11,7 @@ if [ ! -d /var/lib/mysql/mysql ]; then
|
||||||
chown -R mysql:mysql /var/lib/mysql
|
chown -R mysql:mysql /var/lib/mysql
|
||||||
mysql_install_db --user=mysql > /dev/null
|
mysql_install_db --user=mysql > /dev/null
|
||||||
|
|
||||||
if [ ! -z "$MYSQL_ROOT_PASSWORD" ]; then
|
if [ -z "$MYSQL_ROOT_PASSWORD" ]; then
|
||||||
MYSQL_ROOT_PASSWORD=`pwgen -y -s 18 1`
|
MYSQL_ROOT_PASSWORD=`pwgen -y -s 18 1`
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user