Fixes for Newer Versions of MariaDB and MySQL Server

This commit is contained in:
earnolmartin 2019-10-15 09:12:36 -06:00
parent 0ff0682670
commit ca2a2541cc

View file

@ -417,7 +417,7 @@ function mysqlUseLocalHost(){
if [ -e "/etc/mysql/my.cnf" ]; then
sqlModeExists=$(cat "/etc/mysql/my.cnf" | grep -o "^sql_mode")
if [ ! -z "$sqlModeExists" ]; then
sed -i "s/^sql_mode.*/sql_mode=/g" "/etc/mysql/mariadb.conf.d/50-server.cnf"
sed -i "s/^sql_mode.*/sql_mode=/g" "/etc/mysql/my.cnf"
else
echo -e "sql_mode=" >> "/etc/mysql/my.cnf"
fi