SSH 代理转发配置和(似乎)工作,但 github 仍然要求用户 &密码 [英] SSH agent forwarding configured and (seems to be) working but github still asks for user & password
问题描述
我遵循了 github 指南(https://help.github.com/文章/using-ssh-agent-forwarding) 到 ssh 代理转发.
I followed the github guide (https://help.github.com/articles/using-ssh-agent-forwarding) to ssh agent forwarding.
$ ssh -T git@github.com
Attempt to SSH in to github
Hi username! You've successfully authenticated, but GitHub does not provide
shell access.
此命令适用于本地 &服务器.但是当我在服务器上尝试 git pull (或其他与 github 相关的命令)时,它仍然要求我登录 &密码.
This command works on both local & server. But when I try a git pull (or other github related command), on the server, it still asks me for my login & password.
问题是否可能来自于我没有在本地 & 上使用相同的用户名?服务器 ?还是我错过了什么?
Is the problem could come from that I don't use the same username on local & the server ? Or did I miss something else ?
- 本地:ubuntu 11.10
- 服务器:debian 6
推荐答案
SSH 代理仅影响使用 SSH 传输的远程设备.
SSH agents only affect remotes that use the SSH transport.
确保您的遥控器配置为 git@github.com:user/repo.git
,而不是 https://github.com/user/repo.git
.
Make sure your remotes are configured as git@github.com:user/repo.git
, not https://github.com/user/repo.git
.
这篇关于SSH 代理转发配置和(似乎)工作,但 github 仍然要求用户 &密码的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!