mirror of
https://github.com/IT4Change/gradido.git
synced 2025-12-13 07:45:54 +00:00
34 lines
1.1 KiB
Docker
34 lines
1.1 KiB
Docker
FROM phpdockerio/php74-fpm as community_server
|
|
|
|
# install php fpm
|
|
RUN apt-get update \
|
|
&& apt-get -y --no-install-recommends install curl unzip php7.4-curl php7.4-fpm php7.4-mbstring php7.4-intl php7.4-xml php7.4-pdo php7.4-mysql php7.4-xdebug \
|
|
&& apt-get clean; rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* /usr/share/doc/*
|
|
|
|
WORKDIR /var/www/cakephp
|
|
RUN mkdir logs && mkdir tmp && chmod 777 logs && chmod 777 tmp
|
|
COPY ./community_server/ .
|
|
COPY ./configs/community_server/app.php ./config/
|
|
|
|
RUN composer update
|
|
RUN composer dump-autoload
|
|
|
|
|
|
######### special for code coverage and testing
|
|
FROM community_server as test
|
|
|
|
RUN git clone https://github.com/linux-test-project/lcov.git --branch=v1.15 && \
|
|
cd lcov && \
|
|
make install
|
|
|
|
RUN apt-get update \
|
|
&& apt-get -y --no-install-recommends install php7.4-xdebug \
|
|
&& apt-get clean; rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* /usr/share/doc/*
|
|
|
|
WORKDIR /var/www/cakephp
|
|
ENV XDEBUG_MODE=coverage
|
|
|
|
CMD ./vendor/bin/phpunit && lcov --no-external --capture --quiet --output-file ./webroot/coverage/coverage.info
|
|
|
|
|