fix(supported-version): use healthcheck.sh for MariaDB service container#366
Closed
rhoerr wants to merge 3 commits into
Closed
fix(supported-version): use healthcheck.sh for MariaDB service container#366rhoerr wants to merge 3 commits into
rhoerr wants to merge 3 commits into
Conversation
…ealthcheck.sh The official mariadb:11.4 image (used by Magento 2.4.9) no longer ships the mysqladmin binary, so the service-container health command always exits non-zero and the job fails at "Initialize containers". Switch to the bundled healthcheck.sh, which is present in both mariadb:10.6 and mariadb:11.4 — covering every currently-supported lane. Fixes mage-os#365
Root package.json declares @actions/exec@^3.0.0, but the lock file was still pinned to 1.1.1, causing `npm ci` in the Test Actions workflow to fail on any PR that touches supported-version/**. Regenerated via `npm install --package-lock-only` to bring the lock in line.
The previous attempt at a universal healthcheck broke the upstream MySQL lanes (mysql:8.0, mysql:8.4, etc.) because healthcheck.sh is shipped only by the official MariaDB image. Detect the image prefix and use healthcheck.sh for mariadb:* and mysqladmin ping for everything else.
Member
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
mysqladmin pinghealth check in the MySQL service-container template withhealthcheck.sh --connect --innodb_initialized. Themysqladminbinary was removed from the officialmariadb:11.4image (used by Magento 2.4.9), causing thesetup-installlane for 2.4.9 to fail at "Initialize containers" even though MariaDB itself was up.healthcheck.shships in bothmariadb:10.6andmariadb:11.4, so a single template covers every currently-supported lane.build-services.spec.tsand rebuilddist/.package-lock.jsonwithpackage.json(pre-existing drift: root deps declared@actions/exec@^3.0.0, lock was still on1.1.1). Without this, the Test Actions workflow'snpm cistep fails on any PR that touchessupported-version/**.Fixes #365
Test plan
npx jestinsupported-version/— all 111 tests passnpm run buildregeneratesdist/index.jsnpm install --package-lock-onlyproduces a clean lock diffsetup-install (magento/project-community-edition:2.4.9)lane passes on this PRunit-testjob passes on this PR