Repository navigation
Repair wp/5.4 branch Actions: Replace wp-env's database check with a MariaDB health check - #85606
Conversation
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the
|
|
The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message. To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. Props Bot commandsYou can trigger Props Bot actions by commenting on this PR:
|
db02ce3 to
2ab7599
Compare
Part of #83419.
What?
wp-envwaits for the database with a Docker health check instead of runningwp db check. A port of #75046, using the health check command from #83751.Why?
wp db checkruns the MariaDB client in theclicontainer. The currentwordpress:cliimage ships a client (MariaDB 11.8) that requires TLS, and WP-CLI gives no way to turn that off. MariaDB servers before 11.4 don't offer TLS unless configured, so the check fails (SSL is required, but the server does not support it) andwp-env startstops.WP_ENV_MARIADB_VERSION(#85605) can now select one of those servers, andwp-env startfails for anyone who does.trunkfixed this in #75046 by removingwp db checkand waiting for a health check, which doesn't use the client at all.How?
#75046 is ported hunk for hunk, adapted to this branch's
wp-env(one sharedmysqlservice, so it alone gets the health check and both WordPress services wait for it). The health check command comes from #83751 instead, because it works with every MariaDB versionWP_ENV_MARIADB_VERSIONcan select: it uses MariaDB'shealthcheck.shwhere the image supports it, and otherwise pings the server.packages/env/CHANGELOG.mdgetstrunk's entry, and the README note about older MariaDB servers mentions thatwp-env startis no longer affected.Testing Instructions
packages/env's tests run in theJavaScriptjob on this pull request. The CI workflows on this branch usewordpress-develop's environment rather thanwp-env, so the rest was verified locally:packages/env's tests pass, and the generated database service becomes healthy onmariadb:10.4(throughhealthcheck.sh) and onmariadb:10.3(through the ping fallback).Use of AI Tools
This PR was created by Claude Code under my supervision. All code should be treated as AI-produced and not yet reviewed by a human until this PR is marked Ready for Review.
🤖 Generated with Claude Code