php 运行坏境 镜像 build 失败

镜像 build 失败:failed to solve: failed to read expected number of bytes: unexpected EOF

防火墙已关闭,不安装扩展也不行



进入一个容器终端 ping baidu.com 或者 curl www.baidu.com 看看能不能访问互联网
如果不能 就重启 docker

网络是通的,

进入 主机 - 终端 页面,手动拉取一下 PHP 基础镜像,之后再来重新创建运行环境:

docker pull php:7.4.33-fpm-alpine

镜像 build 失败:failed to solve: process “/bin/sh -c chmod +x install.sh && sh install.sh” did not complete successfully: exit code: 1

手动拉取一下 PHP 基础镜像后,关闭服务器防火墙、重启 docker,然后重建运行环境。已解决,感谢!!!