Closed ddeboer closed 1 year ago
A good first step would be to update the tests to reproduce that, then we can iterate on the Dockerfile.
https://github.com/brefphp/extra-php-extensions/blob/master/layers/sqlsrv/test.php
Would you be able to find a way for that?
Sorry, I don’t have time to work on this right now.
If you update line 20 of the test to:
if ($error['SQLSTATE'] == '01000' || $error['SQLSTATE'] == 'IM002') {
You'll see an ODBC error:
FAIL: sqlsrv extension library not loaded. [unixODBC][Driver Manager]Data source name not found, and no default driver specified
I'm not sure the new /bref/lib-copy/copy-dependencies.php
build script is able to find the ODBC msodbcsql17
related required items for sqlsrv
.
We most likely need to pull in some (all?) of those paths still.
👍 we could manually copy files that are not detected automatically by /bref/lib-copy/copy-dependencies.php
Any updates on this issue, I'm facing the same problem
SQLSTATE[01000]: [unixODBC][Driver Manager]Can't open lib '/opt/microsoft/msodbcsql17/lib64/libmsodbcsql-17.10.so.1.1' : file not found
👍 we could manually copy files that are not detected automatically by
/bref/lib-copy/copy-dependencies.php
@mnapoli copy-dependencies.php
seems to be gone, or I’m overlooking it. Has this been changed in the meantime?
@ddeboer it should still be there, it is used by Bref itself: https://github.com/brefphp/aws-lambda-layers/blob/2f4b3f300d559b26cbd9c86bf9ee3f6bd2a6e839/php-80/Dockerfile#L441
I am facing the same issue. Any news on this? How can I help? I just updated a project from bref v1 to v2.
@buddhaCode Please review/test the PR at #474.
@ddeboer Sorry. Took me a while to make a picture of it. But I can confirm that these changes fixes the issue.
No worries @buddhaCode! Thank you for taking the time to test this. A cleaned-up PR is available at #479, but the fix is similar.
On the Bref 2 sqlsrv image: