We have a self-hosted GitLab instance. I’ve created a project with a package registry and I’m successfully deploying packages to the registrying using CI/CD and deploy tokens.
However, I want to be able to add the package registry as a NuGet package source in Visual Studio 2022. Using the VS GUI I’ve added the source, and when I save it I’m prompted for my credentials. When I enter the same username and password as I use to login to out GitLab instance I get a 401: Unauthorised response. I’ve tried every variation of my username and our domain name that I can think of, but nothing works.
How do I authenticate to the package registry in Visual Studio using my username and password?