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

Multiple Package Sources #167

Open
atrauzzi opened this issue Feb 10, 2021 · 9 comments
Open

Multiple Package Sources #167

atrauzzi opened this issue Feb 10, 2021 · 9 comments
Labels
feature request New feature or request to improve the current logic

Comments

@atrauzzi
Copy link

Description:
Opening this as per #75 (comment).

Justification:
Configuring a package source shouldn't preclude me from consuming packages from any other sources. For example, GitHub and Azure Devops are popular for private organization packages. Whereas MyGet is often used for pre-release feeds. Then of course you have Nuget, which while people should be able to disable it, is usually the root-most fallback.

As such, multiple sources should be supported.

Are you willing to submit a PR?
Maybe?

@atrauzzi atrauzzi added the feature request New feature or request to improve the current logic label Feb 10, 2021
@auriorx
Copy link

auriorx commented Feb 21, 2022

@adamralph any update on this? Would be much appreciated.

@adamralph
Copy link
Contributor

wrong username?

@auriorx
Copy link

auriorx commented Feb 21, 2022

Yep, my bad lol

@auriorx
Copy link

auriorx commented Feb 21, 2022

By the way, for anyone struggling with this; you could use the following workaround:

    - name: Setup .NET Core (without a source-url, so default NuGet source is used)
      uses: actions/setup-dotnet@v1
      with:
        dotnet-version: ${{ inputs.dotnet-version }}
    - name: Add Azure Source
      shell: bash
      run: dotnet nuget add source ${{ env.azure-feed }} --name ${{env.azure-source}} --username az --password ${{ env.azure-api-key }} --store-password-in-clear-text
    - name: Push Example
      shell: bash
      run: dotnet nuget push -s ${{ env.azure-source }} --api-key AzureArtifacts ${{env.package-name}}.${{env.software-version}}.nupkg

Things to note:

  • Shell bash might be because my example is based of off a composite action
  • This is for Azure specifcally. Other package sources might require modifications

@rabbi978
Copy link

  1. +8801783217877

@SlyckLizzie
Copy link

SlyckLizzie commented Jun 4, 2023

Any traction on this one? 2+ years now

@IvanZosimov
Copy link
Contributor

Hi, all 👋 Sorry for delayed feedback, we will take a look at this issue!

jdevillard added a commit to jdevillard/elsa-studio that referenced this issue Feb 16, 2024
jdevillard added a commit to jdevillard/elsa-studio that referenced this issue Feb 16, 2024
@jblazek
Copy link

jblazek commented Mar 26, 2024

Any update on this? We have a use case with multiple sources which require authentication.

Something like this config would meet our needs.

- uses: actions/setup-dotnet@v4
  with:
    dotnet-version: 8.0.x
    nuget-sources:
      - url: ''
        token: ''
      - url: ''
        token: ''

DontCallMyPhoneUnlessUGotMeMyCode added a commit to DontCallMyPhoneUnlessUGotMeMyCode/setup-dotnet that referenced this issue Apr 26, 2024
@CoenraadS
Copy link

I worked around the issue like this:

      - name: dotnet
        run: dotnet ...
        env:
          # https://github.com/actions/setup-dotnet/issues/167
          NuGetPackageSourceCredentials_github: Username=${{ github.actor }};Password=${{ secrets.GITHUB_TOKEN }}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request New feature or request to improve the current logic
Projects
None yet
Development

No branches or pull requests

8 participants