相关疑难解决方法(0)

将Git凭证助手与gnome-keyring一起用作Sudo时出错

我正在寻找一种方法来安全地存储凭证,同时连接到使用SSL的Git服务器.我在@james-ward中遇到了这个建议(我编辑的只是我更新了我们的"系统"配置,而不是Git的"全局"配置(/sf/answers/1016985231/)

sudo apt-get install libgnome-keyring-dev
cd /usr/share/doc/git/contrib/credential/gnome-keyring
sudo make
git config --system credential.helper /usr/share/doc/git/contrib/credential/gnome-keyring/git-credential-gnome-keyring
Run Code Online (Sandbox Code Playgroud)

然后我就可以跑了

git clone https://ipaddress/git/repo.git
Run Code Online (Sandbox Code Playgroud)

并且凭证助手将存储我的凭据,但是当我运行以下内容时:

sudo git clone https://ipaddress/git/repo.git testfolder
Run Code Online (Sandbox Code Playgroud)

它给我以下错误

** (process:3713): CRITICAL **: Error communicating with gnome-keyring-daemon
Run Code Online (Sandbox Code Playgroud)

我有时需要运行sudo git clone,因为有时我需要创建克隆的目录需要它.任何帮助,将不胜感激.

我正在使用的版本: - git版本1.9.1 - Ubuntu Server 14.0.4

先感谢您!-Richard O.

linux git ubuntu gnome-keyring-daemon

22
推荐指数
3
解决办法
2万
查看次数

从bitbucket克隆git repo时权限被拒绝(publickey)

我刚刚在bitbucket上创建了git repo.然后我按照以下方式创建ssh密钥:

   1. ssh-keygen -t rsa -C 'dien.vo@asnet.com.vn'
   2. ssh-keygen (press enter more)
   3. cat ~/.ssh/id_rsa.pub --> it return for me a SSH key
   4. Coppy that and added on bitbucket, then I save the new SSH key
Run Code Online (Sandbox Code Playgroud)

之后我选择了SSH链接git git@bitbucket.org:DienVo/abc.git,但是在终端中显示了这一点

sign_and_send_pubkey: signing failed: agent refused operation
Permission denied (publickey).
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.
Run Code Online (Sandbox Code Playgroud)

我不知道我错在哪里,请帮我解决.

git bitbucket ssh-keys

4
推荐指数
1
解决办法
3247
查看次数

一般“未找到 git-credential-libsecret”错误

git repo 没有启用 LFS,但我准备在另一个克隆中使用 git,因此使用git config --global credential.helper似乎是问题的原因。

这里似乎有同样的问题,但我使用的是更新版git(v2.17.0),所以这不是版本问题。

示例:简单之后的git pull消息是

/usr/share/doc/git/contrib/credential/libsecret/git-credential-libsecret get: 1: 
/usr/share/doc/git/contrib/credential/libsecret/git-credential-libsecret get: 
 /usr/share/doc/git/contrib/credential/libsecret/git-credential-libsecret: 
 not found
Run Code Online (Sandbox Code Playgroud)

笔记

没有git-credential-libsecret文件,

sudo ls /usr/share/doc/git/contrib/credential/libsecret/git-credential-libsecret
ls: cannot access '/usr/share/doc/git/contrib/credential/libsecret/git-credential-libsecret': No such file or directory
Run Code Online (Sandbox Code Playgroud)

git credentials

3
推荐指数
1
解决办法
5801
查看次数