fix(apache): Build sqlsrv/pdo_sqlsrv in full image on PHP 8.5 using BuildKit-mounted scripts.#33
Conversation
…ng `BuildKit-mounted` scripts.
📝 WalkthroughWalkthroughRefactors MS SQL Server PHP extension installation from inline Dockerfile commands into two BuildKit-mounted Bash scripts, enabling conditional source-based pdo_sqlsrv compilation for PHP 8.5+. Adds a changelog entry documenting the build fix for sqlsrv/pdo_sqlsrv on PHP 8.5. Changes
Sequence DiagramsequenceDiagram
participant DockerBuild as Docker Build
participant Dockerfile as Dockerfile
participant ExtScript as 10-mssql-php-ext.sh
participant RepoScript as 01-mssql-odbc.sh
participant Apt as System Package Manager
participant PECL as PECL
DockerBuild->>Dockerfile: run full-stage build
Dockerfile->>ExtScript: mount & execute script via RUN --mount
ExtScript->>RepoScript: source helper script
ExtScript->>RepoScript: call mssql_add_apt_repo()
RepoScript->>Apt: add MS ODBC repo & import GPG
ExtScript->>RepoScript: call mssql_install_odbc_runtime()
RepoScript->>Apt: install msodbcsql18 & unixodbc
ExtScript->>PECL: install sqlsrv via PECL
alt PHP >= 8.5
ExtScript->>Apt: download pdo_sqlsrv source, phpize, configure, make, install
else PHP < 8.5
ExtScript->>PECL: install pdo_sqlsrv via PECL
end
ExtScript->>Dockerfile: enable sqlsrv & pdo_sqlsrv in PHP
Dockerfile->>DockerBuild: layer complete
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing touches
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
…in ODBC installation scripts.
Pull Request
Summary by CodeRabbit
Bug Fixes
Documentation
✏️ Tip: You can customize this high-level summary in your review settings.