i was trying to use couchbase as my NosqlDb for my latest php project. While creating docker image i am noticing that the size of image goes high from 195MB to 522MB (after enabling couchbase server as https://developer.couchbase.com/documentation/server/current/sdk/php/start-using-sdk.html). This is adding additional time for file processing and deployment. Doesn’t look right to me please share some thoughts how i can avoid this massive size difference in docker image.
My couchbase server sits on a different server all i need is to communicate my app with db, Is there any way i can just install a light wight extension or library… ?
just FYI i am new to docker and also to couchbase… please forgive if i ask anything silly…
please also check below docker file that i am using to create image…
If it’s just to run an application (in say, Docker Swarm), you shouldn’t need the couchbase-release-1.0-2 package. The pecl install couchbase and dependencies such as libcouchbase are all you need. The pecl extension, intentionally, doesn’t depend on anything in the server package for this use.
If you don’t want to install CentPS or Fedora, I would recommend you to build binaries for module in one image and deploy them in your application image, so that you won’t need all development environment there. Or even better build your own deb package for the module.