Alpine Linux 下安装git或其它软件报错解决
版权声明:
本文为博主原创文章,转载请声明原文链接...谢谢。o_0。
更新时间:
2020-04-22 23:07:50
温馨提示:
学无止境,技术类文章有它的时效性,请留意文章更新时间,如发现内容有误请留言指出,防止别人"踩坑",我会及时更新文章
apk add git && apk add bash
Alpine Linux 下安装git时出现下面错误
fetch http://mirrors.aliyun.com/alpine/v3.10/main/x86_64/APKINDEX.tar.gz
ERROR: http://mirrors.aliyun.com/alpine/v3.10/main: temporary error (try again later)
WARNING: Ignoring APKINDEX.b3d2069c.tar.gz: No such file or directory
fetch http://mirrors.aliyun.com/alpine/v3.10/community/x86_64/APKINDEX.tar.gz
ERROR: http://mirrors.aliyun.com/alpine/v3.10/community: temporary error (try again later)
WARNING: Ignoring APKINDEX.8d865ef8.tar.gz: No such file or directory
ERROR: unsatisfiable constraints:
git (missing):
required by: world[git]
解决方法:
打开宿主机的 /etc/default/docker
添加下面dns解析
DOCKER_OPTS="--dns 114.114.114.114"
再执行上面命令就可以啦