This article is a mirror article of machine translation, please click here to jump to the original article.

View: 3323|Reply: 2

VS 2022 push source code to private Azure DevOps Server issues

[Copy link]
Posted on 9/2/2023 7:08:36 PM | | | |
The Azure DevOps Server team collaborated on the server, and the project was managed with git, and the error was reported when using VS 2022 to push the source code:

master is being pushed
Error when publishing to a remote repository: Git failed with a fatal error.
Git failed with a fatal error.
Authentication failed for 'https://test.itsvse.com/xxx/_git/xxx/'


If you use the command line to push in a way,Entering the username and password can be successfulButUsing VS 2022 will give you an error

Solution: Use SSH key authentication, reference:The hyperlink login is visible.

Create an SSH key

Use PowerShell to create an SSH key with the following command:


Just press Enter all the way to accept the default value, and finally save it in%UserProfile%\.ssh\folder,id_rsa is the private key, and id_rsa.pub is the public key

Long-term storage credential command:



Note: When creating an SSH key,Passphrase is not recommended, otherwise VS 2022 will need to enter every time the pull push is made.

Add the public key to Azure DevOps

Sign in to Azure DevOps Server and select Security in the upper-right corner, as shown in the following image:



Click "SSH Public Key" - > "Add", and fill in the key data in id_rsa.pub.



(End)




Previous:MessagePack and protobuf-net performance benchmarks
Next:National Bank Xbox Series X unlocking cross-region tutorial
 Landlord| Posted on 10/24/2023 8:07:21 PM |
If you encounter the following error in your push:


master is being pushed
Remote: Public key authentication failed.
Error when publishing to a remote repository: Git failed with a fatal error.
Git failed with a fatal error.
Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

solution

at%UserProfile%\.ssh\newly builtconfigThe configuration file is as follows:


Reference:

The hyperlink login is visible.
The hyperlink login is visible.

 Landlord| Posted on 6/15/2024 3:54:38 PM |
How do I specify a private SSH key to use when executing shell commands on Git?

Windows commands:

Reference:The hyperlink login is visible.

Disclaimer:
All software, programming materials or articles published by Code Farmer Network are only for learning and research purposes; The above content shall not be used for commercial or illegal purposes, otherwise, users shall bear all consequences. The information on this site comes from the Internet, and copyright disputes have nothing to do with this site. You must completely delete the above content from your computer within 24 hours of downloading. If you like the program, please support genuine software, purchase registration, and get better genuine services. If there is any infringement, please contact us by email.

Mail To:help@itsvse.com