wordpress-mysql-1 | 2023-09-13T03:24:54.758848Z 0 [System] [MY-011323] [Server] X Plugin ready for connections. Socket: /var/run/mysqld/mysqlx.sock
wordpress-mysql-1 | 2023-09-13T03:24:54.758934Z 0 [System] [MY-010931] [Server] /usr/sbin/mysqld: ready for connections. Version: '8.1.0' socket: '/var/run/mysqld/mysqld.sock' port: 0 MySQL Community Server - GPL.
wordpress-mysql-1 | 2023-09-13T03:24:54.760681Z 0 [System] [MY-015016] [Server] MySQL Server - end.
wordpress-mysql-1 | 2023-09-13 03:24:54+00:00 [Note] [Entrypoint]: Temporary server started.
wordpress-mysql-1 | '/var/lib/mysql/mysql.sock' -> '/var/run/mysqld/mysqld.sock'
... Skip cruft
wordpress-mysql-1 | 2023-09-13 03:24:56+00:00 [Note] [Entrypoint]: Creating user wordpress
wordpress-mysql-1 | 2023-09-13 03:24:56+00:00 [Note] [Entrypoint]: /usr/local/bin/docker-entrypoint.sh: running /docker-entrypoint-initdb.d/import.sql
I can exec in to the container and connect to the socket fine, list databases and see the import worked as expected.
However, I cannot access it through other containers or on the host until I restart, upon which I see:
wordpress-mysql-1 | 2023-09-13T03:28:03.437184Z 0 [System] [MY-011323] [Server] X Plugin ready for connections. Bind-address: '::' port: 33060, socket: /var/run/mysqld/mysqlx.sock
Here you can see it is indicating it's bound to :: and a port, which was missing before.
No amount of waiting starts this binding and requires to manually restart the container (or the entire compose project).
I do realize there is a section in the README called No connections until MySQL init completes, and it says no connections before init - that makes sense. But like I said, I'm able to connect on the socket from within the container just fine, it's init'd - just not binding to IP/PORT for external access.
I'm volume mount binding an SQL file:
On first startup, I see:
I can exec in to the container and connect to the socket fine, list databases and see the import worked as expected.
However, I cannot access it through other containers or on the host until I restart, upon which I see:
Here you can see it is indicating it's bound to
::
and a port, which was missing before.No amount of waiting starts this binding and requires to manually restart the container (or the entire compose project).
I do realize there is a section in the README called
No connections until MySQL init completes
, and it says no connections before init - that makes sense. But like I said, I'm able to connect on the socket from within the container just fine, it's init'd - just not binding to IP/PORT for external access.