Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nuget.config packageSourceCredentials support #30872

Open
rarkins opened this issue Aug 19, 2024 Discussed in #30498 · 0 comments
Open

nuget.config packageSourceCredentials support #30872

rarkins opened this issue Aug 19, 2024 Discussed in #30498 · 0 comments
Labels
manager:nuget NuGeT (.NET) package manager priority-4-low Low priority, unlikely to be done unless it becomes important to more people type:feature Feature (new functionality)

Comments

@rarkins
Copy link
Collaborator

rarkins commented Aug 19, 2024

Discussed in #30498

Originally posted by theKBro July 31, 2024

What would you like help with?

I would like help with my configuration

How are you running Renovate?

Self-hosted

If you're self-hosting Renovate, tell us which platform (GitHub, GitLab, etc) and which version of Renovate.

GitLab with ghcr.io/renovatebot/renovate:37.440.7

Please tell us more about your question or problem

I would like to use renovate to update packages from private nuget repositories.
The nuget.config file contains all information needed to access the private packageSources

<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <packageSources>
    <add key="myPrivateRepo" value="https://gitlab.myCompany.com/api/v4/groups/94/-/packages/nuget/index.json" />
  </packageSources>
  <packageSourceCredentials>
    <myPrivateRepo>
      <add key="Username" value="shared_read" />
      <add key="ClearTextPassword" value="passwordInClearText" />
    </myPrivateRepo>
  </packageSourceCredentials>
</configuration>

but renovate does not seem to use the packageSourceCredentials at all.
We have many different repositories with different read access tokens. Is there any way that this is working or do I need to add hostRules to my runner configuration for all possible autodetected repositories?

Logs (if relevant)

Logs
DEBUG: Found NuGet.config at nuget.config (repository=myRepo)
DEBUG: Adding registry URL https://gitlab.myCompany.com/api/v4/groups/94/-/packages/nuget/index.json (repository=myRepo)
       "registryUrl": "https://gitlab.myCompany.com/api/v4/groups/94/-/packages/nuget/index.json",
       "sourceMappedPackagePatterns": undefined

DEBUG: GET https://gitlab.myCompany.com/api/v4/groups/94/-/packages/nuget/metadata/otherProject/index.json = (code=ERR_NON_2XX_3XX_RESPONSE, statusCode=401 retryCount=0, duration=33) (repository=myRepo)
DEBUG: Datasource unauthorized (repository=myRepo)
       "datasource": "nuget",
       "packageName": "otherProject",
       "url": "https://gitlab.myCompany.com/api/v4/groups/94/-/packages/nuget/metadata/otherProject/index.json"
@rarkins rarkins added type:feature Feature (new functionality) priority-4-low Low priority, unlikely to be done unless it becomes important to more people manager:nuget NuGeT (.NET) package manager labels Aug 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
manager:nuget NuGeT (.NET) package manager priority-4-low Low priority, unlikely to be done unless it becomes important to more people type:feature Feature (new functionality)
Projects
None yet
Development

No branches or pull requests

1 participant