I followed this guide to setup athorization to my nuget-server: http://blog.fermium.io/nuget-server-with-basic-authentication/
For the full authorization solution that I am using you can find it here: https://github.com/devbridge/AzurePowerTools/tree/master/Devbridge.BasicAuthentication
It works fine and when surfing to my nuget-server I get promted to login and it works fine so far. I can also access my existing nuget packages by enter username/password in visual studio.
The problem comes when trying to push a nuget-package from visual studio which worked fine before authorization was added to the nuget-server.
nuget.config (%AppData%\NuGet\NuGet.config)
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<packageSources>
<add key="nuget.org" value="https://www.nuget.org/api/v2/" />
<add key="mynuget" value="http://mynuget.azurewebsites.net/nuget" />
</packageSources>
<activePackageSource>
<add key="All" value="(Aggregate source)" />
</activePackageSource>
<packageSourceCredentials>
<mynuget>
<add key="Username" value="mynugetUsername" />
<add key="ClearTextPassword" value="mynugetPassword" />
</mynuget>
</packageSourceCredentials>
</configuration>
nuget push c:\temp\Packages*.nupkg -s http://mynuget.azurewebsites.net/ apikey -Verbosity detail
Please provide credentials for: http://mynuget.azurewebsites.net/
System.InvalidOperationException: Cannot prompt for input in non-interactive mode.
How can I solve this?