企业🤖AI智能体构建引擎,智能编排和调试,一键部署,支持私有化部署方案 广告
## 此文件少了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 ```