在新的gitlab安装(6.0.1)中推送到新的仓库失败了
Access denied.
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
但ssh -vT git@www.my.gitlab.eu有效。
答案 0 :(得分:8)
何时
sudo -u git -H / home / git / gitlab-shell / bin / check
我得到了:
Check GitLab API access: FAILED. code: 503
Check directories and files:
/home/git/repositories: OK
/home/git/.ssh/authorized_keys: OK
在gitlab-shell.log中,我发现了一个html响应:
ERROR
无法检索请求的网址
尝试检索网址时遇到以下错误: http://my.gitlab.eu//api/v3/internal/check
无法从主机名my.gitlab.eu
确定IP地址DNS服务器返回:
名称错误:域名不存在。这意味着缓存 无法解析URL中显示的主机名。检查是否 地址是正确的。
您的缓存管理员是admin@example.com。
我编辑了gitlab-shell的配置文件
/home/git/gitlab-shell# sudo -u git -H editor config.yml
像这样
# Url to gitlab instance. Used for api calls. Should end with a slash.
#gitlab_url: "http://my.gitlab.eu/"
gitlab_url: "http://123.xxx.xxx.xx"
尽管评论中有暗示,但结束斜线明显导致api跟注中的双斜线。就我而言,dns无法解决。所以现在我使用ip地址,它可以工作。
答案 1 :(得分:0)
关闭selinux。
setenforce 0
还在/ etc / selinux / config中将SELINUX设置为允许。
答案 2 :(得分:0)
检查您的帐户权限。只有所有者才能在master分支中提交。如果您的帐户属于开发人员类型,则需要创建新分支,而所有者的成员会将您的分支与主分支合并。