portia - 在mac下用docker build镜像时,报Failed to fetch

【字号: 日期:2023-03-03浏览:52作者:雯心

问题描述

1.在mac上安装portia,https://github.com/scrapinghub/portiagit clone后使用docker build -t portia . 最后爆出错误

E: Failed to fetch http://archive.ubuntu.com/ubuntu/pool/main/p/python3-defaults/python3-dev_3.4.0-0ubuntu2_amd64.deb Connection failed [IP: 91.189.91.24 80]E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?Command failed (exitcode: 100), exiting...

是因为ubuntu的源要更改吗?

问题解答

回答1:

这是因为在build的时候,从ubuntu官方源下载失败。

可以多试几遍,说不定网络好的时候就成功了。

或者把ubuntu的源改成国内的源:比如163的。注意这个需要修改Dockerfile里面的命令。

不过还是建议直接下载docker镜像:docker pull scrapinghub/portia-on-dash

相关文章: