git set SSH key

Source: Internet
Author: User
Tags ssh
First, create SSH key 1. In the client view there is no key CD ~/.ssh The following figure, is not found in the SSH folder, proves that there is no key

2. Enter the password to create the SSH key ssh-keygen-t rsa-c "Your email" RSA is the key nickname, double quotes is the input email address
The image above can be seen, in the query has no key, will not prompt the folder does not exist, and there are SSH files in the folder, inside is the key
3. There are two files under the SSH folder, one is the private key, the public key is terminated with pub, and the public key is added to the SSH key in Gitlab.
4. Go back to the Git window and add the private key to SSH, the following error is not affected.

5. After adding, you can test it, enter the SSH git@server, the first connection will ask you to confirm, enter the Yesy can. The second connection will directly welcome you.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.