帐户ssh-key与部署ssh-key之间的区别 [英] difference between account ssh-key vs deployment ssh-key

查看:177
本文介绍了帐户ssh-key与部署ssh-key之间的区别的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有人可以解释一下帐户ssh-key与部署ssh-key有什么区别吗?

Can someone please explain what is the difference between account ssh-key vs deployment ssh-key?

我经常使用它们,但从未尝试学习它们的不同之处.

I have made use of them frequently but never tried to learn how they differ.

推荐答案

您的 ssh帐户密钥确实标识您,并允许您在自己与GitHub进行交互(这意味着例如,您可以推送到自己的存储库中

Your ssh account key does identify you, and allows you to interact with GitHub as you (meaning for instance; you can push to your own repo)

您的ssh部署密钥,如"只读的部署密钥"是具有只读访问权限的键.
它无法验证您的身份.

Your ssh deploy key, as mentioned in "Read-only deploy keys" are keys with read-only access.
It does not authenticate you.

部署密钥是SSH密钥,存储在您的服务器上,并授予对单个GitHub存储库的访问权限. 它们通常用于在部署或连续集成运行期间克隆存储库.
部署有时涉及合并分支和推送代码,因此部署密钥始终允许读取和写入访问.由于在许多情况下不需要写访问权限,因此您现在可以使用只读访问权限创建部署密钥.

A deploy key is an SSH key that is stored on your server and grants access to a single GitHub repository. They are often used to clone repositories during deploys or continuous integration runs.
Deploys sometimes involve merging branches and pushing code, so deploy keys have always allowed both read and write access. Because write access is undesirable in many cases, you now have the ability to create deploy keys with read-only access.

您可以创建一个读/写部署密钥,但是它的只读功能与帐户SSH密钥相反:后者(SSH密钥)将始终用于读/写访问您的存储库.

You can create a read/write deploy key, but its ability to be read-only is in contrast with an account SSH key: the latter (SSH key) will always be for read/write access to your repositories.

您在在BitBucket上部署密钥发现了相同的目的:

部署密钥授予对公共或私有存储库的只读访问权限.使用部署密钥,用户或进程可以通过SSH拉或克隆存储库.部署密钥具有以下功能和局限性:

A deployment key grants read-only access to a public or private repository. With a deployment key a user or a process can pull or clone a repository over SSH. Deployment keys have the following features and limitations:

  • 部署密钥不适用于您的计划限制.
  • 您可以将相同的部署密钥添加到多个存储库中.
  • 部署密钥必须是唯一的-它也不能与帐户关联.
  • Deployment keys do not apply to your plan limit.
  • You can add the same deployment key to multiple repositories.
  • The deployment key must be unique — it cannot also be associated with an account.

这篇关于帐户ssh-key与部署ssh-key之间的区别的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆