FROM docker.io/library/php:7-apache ARG GARBAYE_FRAMADATE_FRAMADATE_VERSION RUN apt-get -y update && DEBIAN_FRONTEND=noninteractive apt-get install -y -qq zip unzip git zlib1g-dev libicu-dev g++ default-mysql-client git RUN docker-php-ext-install intl && docker-php-ext-install pdo_mysql RUN a2enmod rewrite COPY --from=docker.io/library/composer:1.10 /usr/bin/composer /usr/bin/composer COPY docker/php.ini /usr/local/etc/php/php.ini COPY docker/apache-framadate.conf /etc/apache2/sites-enabled/framadate.conf COPY docker/entrypoint.sh /usr/local/bin/entrypoint ENV COMPOSER_ALLOW_SUPERUSER=1 RUN set -eux; \ composer global require "hirak/prestissimo:^0.3" --prefer-dist --no-progress --no-suggest --classmap-authoritative; \ composer clear-cache ENV PATH="${PATH}:/root/.composer/vendor/bin" ENV COMPOSER_ALLOW_SUPERUSER 0 WORKDIR /var/www/framadate RUN git clone -b $GARBAYE_FRAMADATE_FRAMADATE_VERSION --depth=1 https://framagit.org/framasoft/framadate/framadate.git . RUN chown -R 33:33 . # Some Apache and PHP configuration RUN if [ "$ENV" = "dev" ] ; then echo Using PHP production mode ; else echo Using PHP development mode && echo "error_reporting = E_ERROR | E_WARNING | E_PARSE\ndisplay_errors = On" > /usr/local/etc/php/conf.d/php.ini ; fi RUN rm /etc/apache2/sites-enabled/000-default.conf EXPOSE 80 ENTRYPOINT ["entrypoint"]