我有一个EC2实例需要两个私人git repos来运行我的应用程序 . 目前,我的python应用程序使用SSH抓取一个repo(公钥在服务器上,并在github上添加为部署密钥) . 问题是我无法使用与其他Deploy Key相同的公钥 - github需要唯一的部署密钥 . 如何配置ec2实例以用于密钥对,或者可能还有另一种方法?
您可以为您的git hub帐户生成一个类似密码的个人访问令牌 .
https://help.github.com/articles/creating-an-access-token-for-command-line-use/
您可以根据需要生成任意数量的这些内容,并且在创建时可以限制令牌允许持有者执行的操作范围 .
https://developer.github.com/v3/oauth/#scopes
然后,您可以使用HTTPS克隆您的存储库,
https://help.github.com/articles/which-remote-url-should-i-use/#cloning-with-https-recommended
1 回答
您可以为您的git hub帐户生成一个类似密码的个人访问令牌 .
https://help.github.com/articles/creating-an-access-token-for-command-line-use/
您可以根据需要生成任意数量的这些内容,并且在创建时可以限制令牌允许持有者执行的操作范围 .
https://developer.github.com/v3/oauth/#scopes
然后,您可以使用HTTPS克隆您的存储库,
https://help.github.com/articles/which-remote-url-should-i-use/#cloning-with-https-recommended