I'm having an issue retrieving my go repository in Azure Devops I followed this instructions on this blog post https://seb-nyberg.medium.com/using-go-modules-with-private-azure-devops-repositories-4664b621f782 I'm using the HTTP but I still ran into some problem.
Steps:
So at first I've created a PAT in Azure DEVOPS
Then execute this in Powershell 7
git config --global url."https://doctor-go:${PAT-TOKEN}@dev.azure.com".insteadOf "https://dev.azure.com"
Next get the repository
go get -v dev.azure.com/GoJack/Doctor-Go/_git/doctor-go-client-service.git
Also my GOPRIVATE path
set GOPRIVATE=dev.azure.com
Error message
# cd .; git ls-remote https://dev.azure.com/GoJack/Doctor-Go/_git/doctor-go-client-service
fatal: Authentication failed for 'https://dev.azure.com/GoJack/Doctor-Go/_git/doctor-go-client-service/'
# cd .; git ls-remote git+ssh://dev.azure.com/GoJack/Doctor-Go/_git/doctor-go-client-service
ssh: connect to host dev.azure.com port 22: Network is unreachable
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
# cd .; git ls-remote ssh://dev.azure.com/GoJack/Doctor-Go/_git/doctor-go-client-service
ssh: connect to host dev.azure.com port 22: Network is unreachable
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
go get: module dev.azure.com/GoJack/Doctor-Go/_git/doctor-go-client-service.git: git ls-remote -q origin in C:\repo\Go\pkg\mod\cache\vcs\ce0ff448242f9d12cad770f534c0eb079d44a6ee26be6ade1eee5255bf833d58: exit status 128:
fatal: unable to connect to dev.azure.com:
dev.azure.com[0: 13.107.42.20]: errno=Unknown error