You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
44 lines
1.1 KiB
44 lines
1.1 KiB
4 months ago
|
FROM php:7.2.34-fpm-alpine3.12
|
||
|
|
||
|
# set timezome
|
||
|
RUN apk add tzdata \
|
||
|
&& ln -sf /usr/share/zoneinfo/Asia/Shanghai /etc/localtime
|
||
|
|
||
|
COPY ./cert.pem /usr/lib/ssl/
|
||
|
COPY ./xdebug-3.1.6.tgz /usr/src/
|
||
|
|
||
|
# 安装ffmpeg
|
||
|
RUN apk add --no-cache ffmpeg
|
||
|
|
||
|
# 安装所需的扩展
|
||
|
RUN apk add \
|
||
|
build-base \
|
||
|
autoconf \
|
||
|
libmcrypt-dev \
|
||
|
libpng-dev \
|
||
|
libzip-dev \
|
||
|
&& docker-php-ext-install -j$(nproc) mbstring bcmath pcntl zip pdo_mysql
|
||
|
RUN apk add --no-cache libjpeg-turbo-dev \
|
||
|
&& docker-php-ext-configure gd --with-jpeg-dir=/usr/include/ \
|
||
|
&& docker-php-ext-install -j$(nproc) gd
|
||
|
RUN pecl install mcrypt-1.0.1 \
|
||
|
&& docker-php-ext-enable mcrypt
|
||
|
RUN curl -sS https://getcomposer.org/installer | php \
|
||
|
&& mv composer.phar /usr/local/bin/composer
|
||
|
RUN cd /usr/src/ \
|
||
|
&& tar -zxvf xdebug-3.1.6.tgz \
|
||
|
&& cd xdebug-3.1.6 \
|
||
|
# 两种方式
|
||
|
# && phpize \
|
||
|
# && ./configure --enable-xdebug \
|
||
|
# && make \
|
||
|
# && make install \
|
||
|
# && docker-php-ext-enable xdebug
|
||
|
# 第二种方式
|
||
|
&& docker-php-ext-configure /usr/src/xdebug-3.1.6 --enable-xdebug \
|
||
|
&& docker-php-ext-install /usr/src/xdebug-3.1.6
|
||
|
|
||
|
|
||
|
|
||
|
|