-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Closed
Description
MySQL SSL connection
When using WORDPRESS_CONFIG_EXTRA ( #142 ) to force MySQL SSL connection (because the server require this) via :
define('MYSQL_CLIENT_FLAGS', MYSQLI_CLIENT_SSL);
The MySQL connection try in entrypoint will not use this setting and slow down the startup by 30 seconds :
wordpress/php7.4/apache/docker-entrypoint.sh
Lines 266 to 277 in b112774
$maxTries = 10; | |
do { | |
$mysql = new mysqli($host, $user, $pass, '', $port, $socket); | |
if ($mysql->connect_error) { | |
fwrite($stderr, "\n" . 'MySQL Connection Error: (' . $mysql->connect_errno . ') ' . $mysql->connect_error . "\n"); | |
--$maxTries; | |
if ($maxTries <= 0) { | |
exit(1); | |
} | |
sleep(3); | |
} | |
} while ($mysql->connect_error); |
During this time the container will loop on this kind of errors :
MySQL Connection Error: (9002) SSL connection is required. Please specify SSL options and retry.
seboss666
Metadata
Metadata
Assignees
Labels
No labels