Closed fg-j closed 3 years ago
We have created an issue in Pivotal Tracker to manage this:
https://www.pivotaltracker.com/story/show/175549373
The labels on this github issue will be updated when the story is started.
The cassandra extension is removed from the buildpack from PHP >= 7.3 according to the release page. I guess because it's not compatible with newer php versions and not maintained anymore, see https://github.com/datastax/php-driver
So that could also explain why the extension is not loaded.
Hi @fg-j,
In your example app, you were adding the ini at .bp-config/php.ini.d/filename.ini
but per documentation you should be adding it at .bp-config/php/php.ini.d/filename.ini
(Notice the missing php
directory). Tested on the with_cassandra
app from your example app and it works:
cf push app4424 -b php4424 -c "php -m" --health-check-type none && cf logs app4424 --recent
Output shows:
2020-12-16T16:46:19.12+0000 [APP/PROC/WEB/0] OUT cassandra
cc @thitch97
What version of Cloud Foundry and CF CLI are you using? (i.e. What is the output of running
cf curl /v2/info && cf version
?What version of the buildpack you are using? 4.4.24
As the following Github issues indicate, (https://github.com/cloudfoundry/php-buildpack/issues/378, https://github.com/cloudfoundry/php-buildpack/issues/341, https://github.com/cloudfoundry/php-buildpack/issues/360) there's an issue with the v2 php buildpack in which it does not load extensions from *.ini files as the docs suggest it should.
As this issue #341 indicates, composer users can work around this issue by adding a platform package for the desired extension. The buildpack will detect the requirement and pull in the necessary extension.
To quickly reproduce the issue:
ini-load-bug
branchscripts/integration.sh
You should see a failure that looks something like:
The expected behaviour is that Cassandra should be loaded as an extension, because it's specified in the
.bp-config/php.ini.d/filename.ini
file.Please confirm where necessary: