github - How does Git create multiple SSH KEYs on one machine and specify a certain KEY when using it?
我想大声告诉你
我想大声告诉你 2017-05-02 09:50:10
0
2
820

The specific problem is that I may have these projects on git now, and then I want to use these projects through different ssh keys.
This requires generating multiple sshkeys on one machine, and then Different projects use different keys when pushing. Has this been used before?
Ask for advice

我想大声告诉你
我想大声告诉你

reply all(2)
小葫芦

No, generally using multiple ssh keys is managed by corresponding to multiple github accounts

Generate the specified key ssh-keygen -t rsa -C "email address" -f ~/.ssh/youname

Modify different hosts

vim ~/.ssh/config

大家讲道理

I don’t think there is such a usage. I think the poster’s request is very strange. However, there are some very practical functions on github that may be of some use to the poster. You can find these functions in the "Settings" menu of github:

  • SSH and GPG keys

You can use multiple ssh-keys or gpg-keys on Github to associate your account, but it cannot meet the requirements of the original poster.

  • Personal access tokens

This is a token-like function, a bit like Oauth's access token. This is how I understand it, that is, when we want to temporarily give a user permission to push to the warehouse, we can generate a Personal access token, grant the corresponding permissions, and then send this permission to that user, and that user can have Push permissions. Isn’t it a bit like a token?

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template