You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
20 lines
388 B
20 lines
388 B
#!/bin/sh
|
|
|
|
|
|
|
|
if ! [ -d /var/lib/mysql/mysql ]; then
|
|
chown -R mysql:mysql /var/lib/mysql
|
|
mysql_install_db --user=mysql --ldata=/var/lib/mysql > /dev/null
|
|
fi
|
|
|
|
|
|
|
|
## Support of Ctrl-C: see https://github.com/docker-library/mysql/issues/47
|
|
run() {
|
|
"$@" &
|
|
pid="$!"
|
|
trap "kill -SIGQUIT $pid" INT TERM
|
|
wait
|
|
}
|
|
|
|
run mysqld --user=mysql --skip-name-resolve --skip-networking=0 "$@"
|