vercel-community / php

🐘 PHP Runtime for ▲ Vercel Serverless Functions (support 7.4-8.3)

Home Page:https://php.vercel.app

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

MongoDB extension

nicgutierrez opened this issue · comments

Feature Request

Hi! Is there any chance we could get the MongoDB extension?

I'm using Laravel and MongoDB but unfortunately the extension is not installed. Cheers!

Hi, I think it's possible. mongodb ext is in REMI's list https://blog.remirepo.net/pages/PECL-extensions-RPM-status. Will do.

Lovely! Thank you @f3l1x : )

Done. Just redeploy your lambdas (e.q. now -f

image

Hey @f3l1x I can confirm the extension is working - thanks for that! However, I'm getting connection issues and I don't know how easy is going to be do debug or fix... anyhow, this is the error I'm getting:

"There's been a server error. Please contact the development team. The error is the following: No suitable servers found (serverSelectionTryOnce set): [Failed to resolve 'mattoneapi.jvgjd.mongodb.net']"

Now, the host seems to be up and running in Mongodb Atlas. I've been searching a bit for the error and it could be related to openSSL..

Here's two threads where the issue is discussed:

mongodb/mongo-php-library#313
mongodb/mongo-php-library#575

Any thoughts? Thanks : )

Hi. Unfortunately I don't use Mongo, so I don't know where is the catch. :-/

Maybe you can test it in Docker with similar environment like AWS Lambda is.

https://github.com/juicyfx/libphp/blob/3658080455397a3664d6b77324d158d508b49991/libs/amazon-linux-2-v74/build/Dockerfile#L1-L51