add development and production targets; run phpunit in container
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
2a0af653cb
commit
9095a604a2
5 changed files with 23 additions and 8 deletions
13
Dockerfile
13
Dockerfile
|
|
@ -1,9 +1,20 @@
|
|||
FROM php:7.4-apache
|
||||
FROM php:7.4-apache AS base
|
||||
|
||||
WORKDIR /var/www
|
||||
|
||||
RUN sed -ri -e 's!/var/www/html!/var/www/public!g' /etc/apache2/sites-available/*.conf
|
||||
|
||||
|
||||
FROM base AS development
|
||||
|
||||
RUN cp $PHP_INI_DIR/php.ini-development $PHP_INI_DIR/php.ini
|
||||
RUN pecl install xdebug && docker-php-ext-enable xdebug
|
||||
|
||||
|
||||
FROM base AS production
|
||||
|
||||
RUN cp $PHP_INI_DIR/php.ini-production $PHP_INI_DIR/php.ini
|
||||
|
||||
COPY vendor/ /var/www/vendor/
|
||||
COPY public/ /var/www/public/
|
||||
COPY src/ /var/www/src/
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue