Skip to content

Instantly share code, notes, and snippets.

@buzzedword buzzedword/Dockerfile
Last active Jun 5, 2018

What would you like to do?
Multistage builds in Docker 17.05
FROM php as vendoring-image
RUN apt-get update && \
apt-get install -y --no-install-recommends git zip
RUN curl --silent --show-error | php && \
mv composer.phar /bin/composer
COPY ./composer.json ./composer.lock /app
RUN composer install
# PS - This is the only image we want to push. Crazy, right?
FROM php:alpine as production-image
RUN mkdir /app
COPY --from=vendoring-image /app/vendors /app/vendors

This comment has been minimized.

Copy link

sonu27 commented May 24, 2018

Should be vendor not vendors

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.