Credentials required pushing to account feed (with API key)

richard's Avatar

richard

25 Jun, 2014 07:26 AM

I'm running into a problem whereby a NuGet is requiring credentials even though I'm supplying an API key. It applies both through my local command line and in an appveyor build via appveyor.yml conifguration.

I have a non-straight forward nuspec configuration, but I otherwise simply want to deploy the nupkg output to my project feed.

Is my assumption that the process is not intended to require username/password correct?

  1. Support Staff 1 Posted by Feodor Fitsner on 25 Jun, 2014 05:56 PM

    Feodor Fitsner's Avatar

    Make sure you are not pushing the package to project feed. Only account feed allows pushing external packages.

    - Feodor

  2. 2 Posted by richard on 25 Jun, 2014 10:51 PM

    richard's Avatar

    Hi Feodor,

    I can confirm that I'm definitely pushing to the account feed. Below is the build output:

    Deploying using NuGet provider
    nuget push "C:\projects\mockhttp\RichardSzalay.MockHttp.1.0.1.22.nupkg" -ApiKey ...
    Pushing RichardSzalay.MockHttp 1.0.1.22 to 'https://ci.appveyor.com/nuget/richardszalay-hf3flrk42bhr'...
    Please provide credentials for: https://ci.appveyor.com/nuget/richardszalay-hf3flrk42bhr
    Process must exit before requested information can be determined.
    

    The API key is taken from https://ci.appveyor.com/nuget, encrypted using https://ci.appveyor.com/tools/encrypt and supplied in the appveyor.yml as such:

    deploy:
      provider: NuGet
      server: https://ci.appveyor.com/nuget/richardszalay-hf3flrk42bhr
      api_key:
        secure: <encrypted key here>
      artifact: /.*\.nupkg/
    

    Cheers,
    Richard

  3. Support Staff 3 Posted by Feodor Fitsner on 26 Jun, 2014 02:53 PM

    Feodor Fitsner's Avatar

    OK, thanks foe the details. I will take a look what's wrong.

    Btw, you don't have to explicitly publish NuGet packages using deployment provider - all NuGet packages pushed to artifacts automatically getting published to both project and account feeds.

  4. 4 Posted by richard on 28 Jun, 2014 02:46 AM

    richard's Avatar

    Thanks for the pointer Feodor, I've removed the explicit nuget push call and it's working as expected.

  5. Support Staff 5 Posted by Feodor Fitsner on 29 Jun, 2014 03:10 AM

    Feodor Fitsner's Avatar

    Nevertheless, there was a bug with enabled feed authentication for package create and delete operations which is already fixed. I will deploy update today.

  6. Support Staff 6 Posted by Feodor Fitsner on 29 Jun, 2014 07:13 AM

    Feodor Fitsner's Avatar

    NuGet feed push authentication issue has been fixed. You should push to a URL of form https://ci.appveyor.com/nuget/<feed-id>/api/v2/package. Update Account NuGet page reflects that.

  7. Ilya Finkelshteyn closed this discussion on 25 Aug, 2018 01:45 AM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac