Skip to content
Advertisement

Unable to locate package in docker image

I am trying to setup a docker image for an app using laravel and postgres but I’m running into difficulties trying to install the php driver for postgres.

My Dockerfile:

JavaScript

The error I am receiving:

JavaScript

Advertisement

Answer

It looks like pgsql is not included in the PHP Docker image.

I used docker-php-extension-installer to add the extensions I need to my Docker image.

I added the following two lines into my dockerfile and everything is working as expected now

JavaScript
User contributions licensed under: CC BY-SA
3 People found this is helpful
Advertisement