Can't push Nuget to Octopus packages repo
Hello,
I have a TeamCity job running on a server that pushes a Nuget package on a Octopus package repo (on a different server). For an unknown reason, this works with many projects on this TeamCity build server, but not this one. And I get the following error:
[13:21:06][Step 2/3] push: Publish package MyService.nupkg (3s)
[13:21:06][push] NuGet command: D:\BuildAgent\plugins\nuget-agent\bin\JetBrains.TeamCity.NuGetRunner.exe D:\BuildAgent\tools\NuGet.CommandLine.3.4.3\tools\NuGet.exe push D:\BuildAgent\work\8f2a3075b6a82181\MyService.nupkg %%teamcity_nuget_api_key_1498044066693%% -Source http://octopus:8080/nuget/packages
[13:21:06][push] Starting: D:\BuildAgent\temp\agentTmp\custom_script9155627391892705881.cmd
[13:21:06][push] in directory: D:\BuildAgent\work\8f2a3075b6a82181
[13:21:06][push] JetBrains TeamCity NuGet Runner 8.0.42538.9
[13:21:06][push] Registered additional extensions from paths: D:\BuildAgent\plugins\nuget-agent\bin\plugins-3.3
[13:21:06][push] Starting NuGet.exe 3.4.3.855 from D:\BuildAgent\tools\NuGet.CommandLine.3.4.3\tools\NuGet.exe
[13:21:07][push] Pushing MyService.nupkg to 'http://octopus:8080/nuget/packages'...
[13:21:07][push] PUT http://octopus:8080/nuget/packages/
[13:21:09][push] Forbidden http://octopus:8080/nuget/packages/ 2338ms
[13:21:09][push] Please provide credentials for: http://octopus:8080/nuget/packages
[13:21:09][push] Cannot prompt for input in non-interactive mode.
[13:21:09][push] UserName:
[13:21:09][push] Process exited with code 1
[13:21:09][Step 2/3] Step Push to Octopus (NuGet Publish) failed
I have read all possible articles on your forums and on the web, but I still can't get this fixed. When publishing manually to the Octopus repository from the BuildServerAgent machine, everything works, using the floowing command:
D:\BuildAgent\tools\NuGet.CommandLine.3.4.3\tools\NuGet.exe push D:\BuildAgent\work\8f2a3075b6a82181\MyService.nupkg "API-XXXXXXXXXXXXXX" -Source http://octopus:8080/nuget/packages
Is there any issue with TeamCity pluggin that your guys would be aware of ? Is there any tricky rights to grant on the target repo (that wouldn't make sense as my other projects are perfectly working)
Let me know if you need more details,
Thank you,
Pierre
Please sign in to leave a comment.
Hi Pierre,
If many other projects are working and this isn't, a configuration problem seems most likely Are this and other projects configured identically? Could you share a couple screenshots of this configuration for a project that fails and one that works?.
Another option could be the nuget server having a specific issue with that package for some reason (permissions? already exists and is read only?) Does the octopus server have some logs about it?
Hello there,
Thank you for your prompt reply.
It was the API key on Octopus side that had been created with a login that didn't have the rights to be a publisher.
Sorted :)
Pierre