In the run script you are executing all sql scripts whit the mysql command like this
*.sql) echo "$0: running $f"; mysql -u $MYSQL_USER -p$MYSQL_PASSWORD $MYSQL_DATABASE < "$f";
but it seems the database isn't started yet, so mysql is not able to connect to the server.
I tried to start the daemon before executing mysql but I wasn't successful, so I just replaced the line with
*.sql) echo "$0: running $f"; /usr/bin/mysqld --user=mysql --bootstrap --skip-name-resolve < $f; echo ;;
This is working for me but I'm not a mariadb expert, so I don't know if this is a feasible solution.
In the run script you are executing all sql scripts whit the mysql command like this
*.sql) echo "$0: running $f"; mysql -u $MYSQL_USER -p$MYSQL_PASSWORD $MYSQL_DATABASE < "$f";
but it seems the database isn't started yet, so mysql is not able to connect to the server.I tried to start the daemon before executing mysql but I wasn't successful, so I just replaced the line with
*.sql) echo "$0: running $f"; /usr/bin/mysqld --user=mysql --bootstrap --skip-name-resolve < $f; echo ;;
This is working for me but I'm not a mariadb expert, so I don't know if this is a feasible solution.