pgsql and pdo are needed in the second stage

This commit is contained in:
Alex Wright 2019-01-22 12:42:41 +01:00
parent 846b0c19d7
commit 7ae20985b1
1 changed files with 3 additions and 4 deletions

View File

@ -1,12 +1,11 @@
FROM composer AS base FROM composer AS base
RUN apk add postgresql-dev openldap-dev \
&& docker-php-ext-install pdo mbstring pdo_pgsql ldap
WORKDIR /app WORKDIR /app
COPY src/composer.json src/composer.lock /app/ COPY src/composer.json src/composer.lock /app/
RUN composer install --no-autoloader RUN composer install --no-autoloader
FROM composer AS install FROM composer
RUN apk add postgresql-dev openldap-dev \
&& docker-php-ext-install pdo mbstring pdo_pgsql ldap
COPY ./src /app COPY ./src /app
COPY --from=base /app/vendor /app/vendor COPY --from=base /app/vendor /app/vendor
RUN composer install RUN composer install