build(docker): update Dockerfile for better setup order
All checks were successful
build / build (pull_request) Successful in 41s
All checks were successful
build / build (pull_request) Successful in 41s
This commit is contained in:
@ -1,11 +1,6 @@
|
|||||||
FROM composer AS composer
|
FROM composer AS composer
|
||||||
FROM php:apache
|
FROM php:apache
|
||||||
|
|
||||||
COPY .. /var/www/html/
|
|
||||||
COPY --from=composer /usr/bin/composer /usr/bin/composer
|
|
||||||
COPY .docker/hosts/abiball.conf /etc/apache2/sites-enabled
|
|
||||||
|
|
||||||
RUN chown -R www-data:www-data /var/www/html
|
|
||||||
RUN rm /etc/apache2/sites-enabled/000-default.conf
|
RUN rm /etc/apache2/sites-enabled/000-default.conf
|
||||||
|
|
||||||
RUN apt-get update
|
RUN apt-get update
|
||||||
@ -17,7 +12,14 @@ RUN a2enmod rewrite
|
|||||||
RUN pecl install apcu && docker-php-ext-enable apcu
|
RUN pecl install apcu && docker-php-ext-enable apcu
|
||||||
|
|
||||||
WORKDIR /var/www/html
|
WORKDIR /var/www/html
|
||||||
|
|
||||||
|
COPY .. /var/www/html/
|
||||||
|
COPY --from=composer /usr/bin/composer /usr/bin/composer
|
||||||
|
COPY .docker/hosts/abiball.conf /etc/apache2/sites-enabled
|
||||||
|
|
||||||
|
RUN chown -R www-data:www-data /var/www/html
|
||||||
|
|
||||||
RUN composer install --optimize-autoloader --no-suggest --no-progress
|
RUN composer install --optimize-autoloader --no-suggest --no-progress
|
||||||
RUN php bin/console tailwind:build
|
RUN php bin/console tailwind:build
|
||||||
RUN php bin/console asset-map:compile
|
RUN php bin/console asset-map:compile
|
||||||
RUN echo "APP_ENV=prod" > .env.local
|
RUN echo "APP_ENV=prod" > .env.local
|
||||||
|
Reference in New Issue
Block a user