2021-01-30 11:31:08 +03:00
|
|
|
FROM php:8.0.1-fpm-alpine3.13
|
2017-01-20 00:56:45 +03:00
|
|
|
MAINTAINER Alejandro Celaya <alejandro@alejandrocelaya.com>
|
|
|
|
|
2021-01-30 11:31:08 +03:00
|
|
|
ENV APCU_VERSION 5.1.19
|
|
|
|
ENV PDO_SQLSRV_VERSION 5.9.0
|
2019-02-02 12:53:34 +03:00
|
|
|
|
2017-01-20 00:56:45 +03:00
|
|
|
RUN apk update
|
|
|
|
|
|
|
|
# Install common php extensions
|
|
|
|
RUN docker-php-ext-install pdo_mysql
|
|
|
|
RUN docker-php-ext-install iconv
|
|
|
|
RUN docker-php-ext-install calendar
|
|
|
|
|
2019-12-17 13:21:47 +03:00
|
|
|
RUN apk add --no-cache oniguruma-dev
|
|
|
|
RUN docker-php-ext-install mbstring
|
|
|
|
|
2019-11-16 00:05:34 +03:00
|
|
|
RUN apk add --no-cache sqlite-libs
|
|
|
|
RUN apk add --no-cache sqlite-dev
|
2017-01-20 00:56:45 +03:00
|
|
|
RUN docker-php-ext-install pdo_sqlite
|
|
|
|
|
2019-11-16 00:05:34 +03:00
|
|
|
RUN apk add --no-cache icu-dev
|
2019-11-16 11:46:42 +03:00
|
|
|
RUN docker-php-ext-install intl
|
2017-01-20 00:56:45 +03:00
|
|
|
|
2019-11-16 00:05:34 +03:00
|
|
|
RUN apk add --no-cache libzip-dev zlib-dev
|
2017-01-20 00:56:45 +03:00
|
|
|
RUN docker-php-ext-install zip
|
|
|
|
|
2019-11-16 00:05:34 +03:00
|
|
|
RUN apk add --no-cache libpng-dev
|
2017-01-20 00:56:45 +03:00
|
|
|
RUN docker-php-ext-install gd
|
|
|
|
|
2019-03-05 15:39:45 +03:00
|
|
|
RUN apk add --no-cache postgresql-dev
|
|
|
|
RUN docker-php-ext-install pdo_pgsql
|
|
|
|
|
2020-11-02 11:02:00 +03:00
|
|
|
RUN apk add --no-cache gmp-dev
|
|
|
|
RUN docker-php-ext-install gmp
|
|
|
|
|
2017-01-20 00:56:45 +03:00
|
|
|
# Install APCu extension
|
2019-02-02 12:53:34 +03:00
|
|
|
ADD https://pecl.php.net/get/apcu-$APCU_VERSION.tgz /tmp/apcu.tar.gz
|
2021-01-30 11:31:08 +03:00
|
|
|
RUN mkdir -p /usr/src/php/ext/apcu \
|
|
|
|
&& tar xf /tmp/apcu.tar.gz -C /usr/src/php/ext/apcu --strip-components=1 \
|
|
|
|
&& docker-php-ext-configure apcu \
|
|
|
|
&& docker-php-ext-install apcu \
|
|
|
|
&& rm /tmp/apcu.tar.gz \
|
|
|
|
&& rm /usr/local/etc/php/conf.d/docker-php-ext-apcu.ini \
|
|
|
|
&& echo extension=apcu.so > /usr/local/etc/php/conf.d/20-php-ext-apcu.ini
|
2017-01-20 00:56:45 +03:00
|
|
|
|
2020-09-26 11:43:50 +03:00
|
|
|
# Install pcov and sqlsrv driver
|
2020-02-03 23:20:40 +03:00
|
|
|
RUN wget https://download.microsoft.com/download/e/4/e/e4e67866-dffd-428c-aac7-8d28ddafb39b/msodbcsql17_17.5.1.1-1_amd64.apk && \
|
|
|
|
apk add --allow-untrusted msodbcsql17_17.5.1.1-1_amd64.apk && \
|
|
|
|
apk add --no-cache --virtual .phpize-deps $PHPIZE_DEPS unixodbc-dev && \
|
2021-01-30 11:31:08 +03:00
|
|
|
pecl install pdo_sqlsrv-${PDO_SQLSRV_VERSION} pcov && \
|
2020-09-26 11:43:50 +03:00
|
|
|
docker-php-ext-enable pdo_sqlsrv pcov && \
|
2020-02-03 23:20:40 +03:00
|
|
|
apk del .phpize-deps && \
|
2020-05-07 11:16:20 +03:00
|
|
|
rm msodbcsql17_17.5.1.1-1_amd64.apk
|
2020-02-03 23:20:40 +03:00
|
|
|
|
2017-01-20 00:56:45 +03:00
|
|
|
# Install composer
|
2020-10-25 19:59:37 +03:00
|
|
|
COPY --from=composer:2 /usr/bin/composer /usr/local/bin/composer
|
2017-10-12 10:24:47 +03:00
|
|
|
|
|
|
|
# Make home directory writable by anyone
|
|
|
|
RUN chmod 777 /home
|