2019-11-07 19:02:50 +00:00
|
|
|
FROM php:7.3-fpm-alpine
|
2019-11-05 15:06:24 +00:00
|
|
|
|
2019-11-07 19:02:50 +00:00
|
|
|
RUN apk add --no-cache --virtual .build-deps \
|
|
|
|
$PHPIZE_DEPS \
|
|
|
|
curl-dev \
|
|
|
|
imagemagick-dev \
|
|
|
|
libtool \
|
|
|
|
libxml2-dev \
|
|
|
|
postgresql-dev \
|
|
|
|
sqlite-dev \
|
|
|
|
&& apk add --no-cache \
|
|
|
|
curl \
|
|
|
|
git \
|
|
|
|
gd \
|
|
|
|
imagemagick \
|
|
|
|
mysql-client \
|
|
|
|
postgresql-libs \
|
|
|
|
libintl \
|
|
|
|
icu \
|
|
|
|
icu-dev \
|
|
|
|
libzip-dev \
|
|
|
|
&& pecl install imagick \
|
|
|
|
&& docker-php-ext-enable imagick \
|
|
|
|
&& apk add --no-cache freetype libpng libjpeg-turbo freetype-dev libpng-dev libjpeg-turbo-dev && \
|
|
|
|
docker-php-ext-configure gd \
|
|
|
|
--with-gd \
|
|
|
|
--with-freetype-dir=/usr/include/ \
|
|
|
|
--with-png-dir=/usr/include/ \
|
|
|
|
--with-jpeg-dir=/usr/include/ && \
|
|
|
|
NPROC=$(grep -c ^processor /proc/cpuinfo 2>/dev/null || 1) && \
|
|
|
|
docker-php-ext-install -j${NPROC} gd && \
|
|
|
|
apk del --no-cache freetype-dev libpng-dev libjpeg-turbo-dev \
|
|
|
|
&& docker-php-ext-install \
|
|
|
|
bcmath \
|
|
|
|
curl \
|
|
|
|
iconv \
|
|
|
|
mbstring \
|
|
|
|
pdo \
|
|
|
|
pdo_mysql \
|
|
|
|
pdo_pgsql \
|
|
|
|
pdo_sqlite \
|
|
|
|
pcntl \
|
|
|
|
tokenizer \
|
|
|
|
xml \
|
|
|
|
zip \
|
|
|
|
intl \
|
|
|
|
&& apk del -f .build-deps
|
2019-11-05 15:06:24 +00:00
|
|
|
|
|
|
|
COPY --from=composer:latest /usr/bin/composer /usr/bin/composer
|
|
|
|
|
|
|
|
ENV COMPOSER_ALLOW_SUPERUSER=1
|
|
|
|
RUN composer global require hirak/prestissimo --prefer-dist --no-progress --no-suggest --classmap-authoritative \
|
|
|
|
&& composer clear-cache
|
|
|
|
ENV PATH="${PATH}:/root/.composer/vendor/bin"
|
|
|
|
|
2019-11-07 19:02:50 +00:00
|
|
|
WORKDIR /var/www/html
|
|
|
|
RUN mkdir -p storage bootstrap/cache
|
2019-11-05 15:06:24 +00:00
|
|
|
# Authorize these folders to be edited
|
2019-11-07 19:02:50 +00:00
|
|
|
RUN chmod -R 777 storage bootstrap/cache
|