-
Notifications
You must be signed in to change notification settings - Fork 258
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
Improved proxy support in the NuGet.Clients (ntlm proxy, etc) #6981
Comments
@tebeco did you come up with any alternative solution so far ? |
not really though JFrog need to fix tons of bug for example i cannot proxyfy |
seems like a hack that may do the work, I will check it out |
its very problematic when i clone repository like and i attempt to restore/build il order to navigate in the code for exemple, another issue is that sources are split between finally there's like 4 to 8 differents feed so i have to create them at least once so at the beginning you have to create them one by one |
Any updates on that issue? Just run into the 407 due to our NTLM authenticated proxy and since we migrated to Always On VPN, I cannot even circumvent the proxy... |
Getting a 403 because
|
some of you might be running into a different issue that is actually easy to workaround. If you have a fixed proxy address that you can point at (which you can sometimes work out from the pac script), then you can tell Nuget about it and it will happily deal with NTLM I believe. It needs to be configured in your central nuget.config under
|
My issue is that we need to use proxy for a single source. and not for others. We have HTTP_PROXY set so that everything picks it up correctly. We also have NO_PROXY set for various domains/IP ranges that cannot go through the proxy. Global <?xml version="1.0" encoding="utf-8"?>
<configuration>
<packageSources>
<!-- This needs to go through Proxy -->
<add key="nuget.org" value="https://api.nuget.org/v3/index.json" protocolVersion="3" />
<!-- This cannot go through Proxy. Has exclusion in NO_PRXY -->
<add key="TeamCityInternal" value="http://nuget.internal/" />
</packageSources>
</configuration> And then we have
This works perfectly fine when running It doesn't work when running Using |
In my case I had to set http_proxy in global nuget not local one as @mungojam said. But why is it not possible to set it in local nuget.config ? It is very confusing because |
the current nuget config is flawed the moment you have a source on public internet like nuget.org that needs a proxy and an on premise solution like sonarype/artifactory and you should skip proxy or an in cloud private feed which require another proxy route nuget team should move the "proxy" settings INSIDE the feed idea 1 feed => 1 or 0 proxy until that's done i strongly suggest you don't rely on proxy nuget client side and you ask you IT to setup a proxy feed to do that heavy lifting to reach outside feed with the configuration properly doing the proxy stuff per feed you could even run a Baget instance locally but the moment you have teammate ... having a nuget feed acting as a proxy is also supposed to help bandwith / latency assuming caching policy is done properly |
Details about Problem
NuGet product used :
NuGet version :
NuGet Version: 4.6.0.4971
dotnet.exe --version :
2.1.300-rc1-008673 [C:\Program Files\dotnet\sdk]
VS version :
Vs2017 15.7.2
OS version :
Worked before? Never probably ?
Detailed repro steps so we can see the same problem
pac url
(like :SET HTTP_PROXY=http://foo/bar/corp_proxyXYW.pac
)Nuget install
with something like :WITHOUT anything in the HTTP_PROXY :
C:\Program Files\dotnet\sdk\2.1.300-rc1-008673\NuGet.targets(114,5): error : Unable to load the service index for source https://www.myget.org/F/fake-vsts/api/v3/index.json.
With it :
C:\Program Files\dotnet\sdk\2.1.300-rc1-008673\NuGet.targets(114,5): error : Response status code does not indicate success: 400 (Bad Request)
With the "real" proxy URL ... since i use both internal feed and external feed ... i have to set NO_PROXY ?
If there's no simple pattern for no_proxy ... how do i deal with it
The guys that are paid in corp to design the
PAC Script
took time to handle all that nicely so it would be fine using it right ?Output :
I will not set any user/password in an Env variable either because i would have to do so :
NO_PROXY
it will destroy tool likenpm
yarn
deploy stuffHow are we supposed to use
dotnet
behind an NTLM proxy ?The text was updated successfully, but these errors were encountered: