Tags: cloudfoundry/php-buildpack
Tags
Fix Go 1.26 build compatibility: remove bin stubs before go build
Go 1.26 refuses to overwrite non-object files with 'go build -o'.
Add 'rm -f "${output}"' before each go build invocation so the
shell script stubs in bin/ are removed first.
fix: replace util.CopyFile with custom copyFile implementation in fin… …alize The util package's CopyFile was removed, causing finalize to fail when copying the pre-compiled rewrite binary to .bp/bin/rewrite. This change: - Adds a copyFile() method to Finalizer that preserves file permissions - Removes dependency on the removed util package - Updates tests to reflect the simplified file copy approach The rewrite binary is pre-compiled by scripts/build.sh during packaging and copied to the app's .bp/bin/ directory during finalize, making it available for runtime configuration templating. Integration tests pass successfully.
refactor: remove hardcoded versions from AppDynamics and NewRelic ext… …ensions Replace hardcoded version strings and URLs with dynamic lookups from manifest.yml using InstallOnlyVersion(). This ensures extension versions are always pulled from the manifest, eliminating the need to update code when bumping dependency versions. Changes: - Add InstallOnlyVersion() wrapper method to extensions.Installer - Update AppDynamics extension to use InstallOnlyVersion() - Update NewRelic extension to use InstallOnlyVersion() - Remove hardcoded version 23.11.0-839 from AppDynamics - Remove manual URL construction logic This follows the same pattern used by PHP, HTTPD, and Nginx installations in the buildpack.
Fix offline test log matcher to use ContainSubstring The offline test was using ContainLines() to check for 'Generating autoload files' in the logs, which fails on Cloud Foundry because the logs channel may be consumed or closed after deployment completes, making line-by-line matching unreliable. Changed to use ContainSubstring() wrapped in SatisfyAll(), matching the pattern used by all other working tests (composer_test.go, modules_test.go, etc.). This fixes the test failure that occurred only on Cloud Foundry platform where the test would timeout after 30 seconds even though the message was present in the staging logs.
PreviousNext