配置yum仓库的时候执行命令报错

来源:2-3 GitLab安装配置管理

Mystery丶微光

2018-09-04

curl -sS https://packages.gitlab.com/install/repositories/gitlab/gitlab-ce/script.rpm.sh | sudo bash  

报错如下:

failure: repodata/repomd.xml from gitlab_gitlab-ce: [Errno 256] No more mirrors to try.

https://packages.gitlab.com/gitlab/gitlab-ce/el/7/x86_64/repodata/repomd.xml: [Errno 14] curl#6 - "Could not resolve host: packages.gitlab.com; 未知的名称或服务"

这个是没有资源了吗?

写回答

4回答

一路向北

2018-09-05

感谢这位同学的关注,涉及到外网仓库源下载的问题,可能每个人的本地网络稳定性都不太一样,建议结合报错信息多试几次。

0
1
Mystery丶微光
非常感谢!
2018-09-05
共1条回复

一路向北

2018-09-05

估计还是和网络有关,可以尝试国内的镜像

0
0

Mystery丶微光

提问者

2018-09-05

今天重新安装还是不行,重新换了安装源,用的是清华大学的镜像。https://www.unixhot.com/article/48

[root@linux-node2 ~]# vim /etc/yum.repos.d/gitlab-ce.repo
[gitlab-ce]
name=gitlab-ce
baseurl=https://mirrors.tuna.tsinghua.edu.cn/gitlab-ce/yum/el7/
repo_gpgcheck=0
gpgcheck=0
enabled=1
gpgkey=https://packages.gitlab.com/gpg.key
[root@linux-node2 ~]# yum makecache
[root@linux-node2 ~]# yum install gitlab-ce


0
0

Mystery丶微光

提问者

2018-09-04

已解决,在安装的时候执行了两次命令,第二次成功了。第二次的时候自动更换了资源

0
0

Jenkins+Ansible+Gitlab-三剑合璧掌握自动化部署

整合三大工具解决自动化部署&持续交付问题

1290 学习 · 319 问题

查看课程