## 此文件少了redis和xdebug扩展,需要自行安装
```
FROM php:7.2-fpm
# 设置时区
ENV TZ=Asia/Shanghai
RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone
# 处理中文乱码问题
ENV LANG "C.UTF-8"
RUN sed -i "s@http://deb.debian.org@https://mirrors.aliyun.com@g" /etc/apt/sources.list && rm -Rf /var/lib/apt/lists/*
RUN apt-get update
# PHP用户
RUN usermod -u 1000 www-data
# 更新安装依赖包和PHP核心拓展
RUN apt-get install -y \
libfreetype6-dev \
libjpeg62-turbo-dev \
libpng-dev \
libmemcached-dev \
libsasl2-dev \
wget \
zip \
unzip \
libgmp-dev \
libssl-dev \
openssl \
vim \
cron \
supervisor \
&& docker-php-ext-configure gd --with-freetype-dir=/usr/include/ --with-jpeg-dir=/usr/include/ \
&& docker-php-ext-install -j$(nproc) gd \
&& docker-php-ext-install bcmath \
&& docker-php-ext-install gmp \
&& docker-php-ext-install zip \
&& docker-php-ext-install pdo_mysql \
&& docker-php-ext-install opcache \
&& docker-php-ext-install mysqli \
&& pecl channel-update pecl.php.net \
&& pecl install mongodb \
&& docker-php-ext-enable mongodb \
&& export EDITOR=vim
# 安装 composer
RUN php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');" \
&& php composer-setup.php --install-dir=/usr/local/bin --filename=composer \
&& php -r "unlink('composer-setup.php');" \
&& chown -R www-data:www-data /var/www/
USER www-data
RUN composer config -g repo.packagist composer https://mirrors.aliyun.com/composer/ \
&& composer self-update
WORKDIR /workspace/html
```
- Docker容器化部署使用说明书
- 环境部署
- Windows系统
- Windows部署Docker
- 安装过程可能碰到的问题总结
- Docker部署环境
- Docker hub操作
- Docker 部署 laravel5.5问题总结
- Docker处理中文乱码问题
- Linux系统
- Centos7.2部署Docker
- Linux部署Docker准备前工作
- 部署docker问题总结
- Linux部署Docker粗略笔记
- 安装git
- Docker命令大全
- 问题
- php7.4 安装xlswriter扩展
- php7.2 DockerFile文件
- dockerFile和docker-composer区别
- docker-compose的使用
- docker-compose的使用问题总结
- docker-compose
- Windows系统
- docker-compose.yml编写
- nginx目录如下
- conf.d
- default.conf
- nginx.conf
- php目录如下
- Dockerfile
- redis目录如下
- redis.conf
- docker-compose使用说明
- Linux系统
- /workspace/html/config_dev
- html
- index.html
- index.php
- nginx
- conf
- nginx.production.conf
- conf.d
- default.conf
- log
- access.log
- error.log
- Dockerfile
- php
- conf
- php.production.ini
- php-fpm.conf
- log(目录)
- php-fpm.d
- www.conf
- supervisor
- conf
- log
- Dockerfile
- .env
- docker-compose.yml