Skip to content

Commit 18ec190

Browse files
committed
Merge pull request docker-library#78 from mysql/master
Prevent mysqld --verbose --help from writing to empty datadir
2 parents 9041eeb + e80af3b commit 18ec190

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

5.7/docker-entrypoint.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ fi
1717

1818
if [ "$1" = 'mysqld' ]; then
1919
# Get config
20-
DATADIR="$("$@" --verbose --help 2>/dev/null | awk '$1 == "datadir" { print $2; exit }')"
20+
DATADIR="$("$@" --verbose --help --innodb-read-only 2>/dev/null | awk '$1 == "datadir" { print $2; exit }')"
2121
SOCKET=$(get_option mysqld socket "$DATADIR/mysql.sock")
2222
PIDFILE=$(get_option mysqld pid-file "/var/run/mysqld/mysqld.pid")
2323

0 commit comments

Comments
 (0)