[英]git clone from internal gitlab repository doesn't work unless I'm running as root
I'm trying to clone an internal gitlab repository, but it keeps giving me this error message我正在尝试克隆一个内部 gitlab 存储库,但它一直给我这个错误消息
fatal: unable to access 'https://gitlab**************.git/': gnutls_handshake() failed: Error in the pull function.
But somehow, if I'm running as root, the cloning process would run perfectly.但不知何故,如果我以 root 身份运行,克隆过程将完美运行。
The problem is, I needed this to work because I'm trying to use this repository on Jenkins.问题是,我需要它来工作,因为我试图在 Jenkins 上使用这个存储库。
Can someone help me or explain why it only worked if I'm running as root?有人可以帮助我或解释为什么它只在我以 root 身份运行时才有效吗?
root uses the same version of git and curl. root 使用相同版本的 git 和 curl。
But it does not use the same:但它不使用相同的:
git config --global -l
in both instances (root and regular user account).全局 git 配置:比较 git 配置的git config --global -l
在两个实例(root 和普通用户帐户)。env
in both cases, and compare the environment variables)环境配置(在两种情况下都输入env
,并比较环境变量) In particular, look for sslcainfo
( git config --global -l|grep -i ssl
) which could reference the certificate needed to contact through TLS your on-premise HTTPS GitLab URL. In particular, look for sslcainfo
( git config --global -l|grep -i ssl
) which could reference the certificate needed to contact through TLS your on-premise HTTPS GitLab URL.
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.