Closed hoey94 closed 1 year ago
重新修改了php-mysql/DockerFile文件以后,可以正常运行,因为官方源不能在国内使用,这里替换成中科大的源就可以了
FROM php:5.6-fpm
RUN echo 'deb http://mirrors.ustc.edu.cn/debian buster main contrib non-free' > /etc/apt/sources.list \
&& echo 'deb http://mirrors.ustc.edu.cn/debian buster-updates main contrib non-free' >> /etc/apt/sources.list \
&& echo 'deb http://mirrors.ustc.edu.cn/debian buster-backports main contrib non-free' >> /etc/apt/sources.list \
&& echo 'deb http://mirrors.ustc.edu.cn/debian-security/ buster/updates main contrib non-free' >> /etc/apt/sources.list \
&& echo 'deb-src http://mirrors.ustc.edu.cn/debian buster main contrib non-free' >> /etc/apt/sources.list \
&& echo 'deb-src http://mirrors.ustc.edu.cn/debian buster-updates main contrib non-free' >> /etc/apt/sources.list \
&& echo 'deb-src http://mirrors.ustc.edu.cn/debian buster-backports main contrib non-free' >> /etc/apt/sources.list \
&& echo 'deb-src http://mirrors.ustc.edu.cn/debian-security/ buster/updates main contrib non-free' >> /etc/apt/sources.list \
&& rm -rf /var/lib/apt/lists/*
RUN apt-get clean
RUN apt-get update \
&& apt-get install -y --allow-unauthenticated iputils-ping \
&& docker-php-ext-install mysqli && docker-php-ext-enable mysqli
部署的时候php安装失败了,使用的是手动docker-compose安装