move src code copy to second stage

this enables better caching in case the dependencies
stay the same and the only actual code changed
master
lub 5 years ago
parent f10a9e39c5
commit add4beee31

@ -2,7 +2,7 @@ FROM docker.io/composer AS composer
WORKDIR /app WORKDIR /app
COPY composer.json main.php functions.php ./ COPY composer.json ./
RUN composer install RUN composer install
@ -11,6 +11,7 @@ RUN composer install
FROM docker.io/php:alpine FROM docker.io/php:alpine
COPY --from=composer /app /app COPY --from=composer /app /app
COPY main.php functions.php ./
WORKDIR /app WORKDIR /app

Loading…
Cancel
Save