Dockerfile 1.2 KB

123456789101112131415161718192021
  1. FROM php:fpm-alpine
  2. RUN apk update && apk add git autoconf make file gettext-dev icu-dev zlib-dev libpng-dev gmp-dev \
  3. mariadb-dev mariadb-client postgresql-dev postgresql-client composer > /dev/null
  4. ARG exts=" bcmath exif gd gettext gmp intl mysqli opcache pdo pdo_mysql mysqli pdo_pgsql pgsql"
  5. RUN apk add --virtual .phpize-deps $PHPIZE_DEPS \
  6. && cd /tmp && git clone https://github.com/krakjoe/apcu && cd apcu && phpize && ./configure --enable-apcu && make install \
  7. && cd /tmp && git clone https://github.com/php-ds/ext-ds && cd ext-ds && phpize && ./configure && make install \
  8. && cd /tmp && git clone https://github.com/msgpack/msgpack-php && cd msgpack-php && phpize && ./configure && make install \
  9. && cd /tmp && git clone https://github.com/lz4/lz4 && cd lz4 && make install \
  10. && cd /tmp && git clone https://github.com/phpredis/phpredis && cd phpredis && phpize && ./configure --enable-redis-msgpack --enable-redis-lz4 --with-liblz4=yes && make install \
  11. && rm -rf /usr/share/php7 \
  12. && rm -rf /tmp/* \
  13. && apk del .phpize-deps > /dev/null
  14. RUN docker-php-ext-install ${exts} && docker-php-ext-enable ds msgpack redis apcu
  15. WORKDIR /var/www/social