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

Add support for custom internet proxy credentials with env vars #1061

Merged
merged 1 commit into from
Sep 16, 2015

Conversation

dedale
Copy link
Contributor

@dedale dedale commented Sep 14, 2015

At work our internet proxy uses custom credentials (different from Active Directory standard credentials). E.g AD login is like sforkman150915 but proxy login is steffen.forkmann.

By default, Paket and bootstrapper set default credentials in IWebProxy. They fail with 407 if I want to use them. I've seen other strange behaviors like partial nuget conversion. I cannot use FsReveal for the same reasons (407!)

At work some of our tools use the following env vars: http_proxy, https_proxy and no_proxy (bypass list).

So I added support for these variables in Paket and bootstrapper.

I did it twice (once in C# for bootstrapper and once in F# for Paket Utils). I could not come with a pretty solution to factor this.

I tried to add as many tests as I could (did not test all the possibilities though)

Please review this commit. I'm not very fluent in F# yet.
I am wondering if env var are case sensitive in mono environment.

See also: https://msdn.microsoft.com/fr-fr/library/Hh272656.aspx

Next step: try to convince my team to ditch nuget...

@forki
Copy link
Member

forki commented Sep 15, 2015

/cc @vasily-kirichenko could you please take a look if this would still work for you? Thx

@forki
Copy link
Member

forki commented Sep 15, 2015

Seems the tests fail on TravisCI / mono ;-)

@forki forki force-pushed the master branch 3 times, most recently from 225c445 to 908e045 Compare September 15, 2015 08:06
@forki
Copy link
Member

forki commented Sep 15, 2015

and could you please rebase the PR? thx

@vasily-kirichenko
Copy link
Contributor

Sorry, I'm on a vocation till 23/09.

@dedale
Copy link
Contributor Author

dedale commented Sep 15, 2015

I will rebase the PR.
I need to setup some linux distro in VirtualBox to fix the mono failures (I dont think I can reproduce on Windows)

@dedale
Copy link
Contributor Author

dedale commented Sep 15, 2015

I'm trying tro reproduce travis/mono failures.
I have installed the following ubuntu packages: fsharp 4.0.0.3-0xamarin1, mono-complete 4.0.4.1-0xamarin1.
Unfortunately, building paket fails with very strange errors:

image

@dedale
Copy link
Contributor Author

dedale commented Sep 15, 2015

Well problem disappeared after a couple of reinstallations and playing with alpha and beta mono channels. Not understood... No I can reproduce my bugs on mono.

@dedale
Copy link
Contributor Author

dedale commented Sep 15, 2015

Env vars ARE case sensitive under mono environment. Should be fixed now (too late to wait for CI builds)... 💤

@dedale
Copy link
Contributor Author

dedale commented Sep 15, 2015

✌️ wow this was fast!

@forki
Copy link
Member

forki commented Sep 16, 2015

danger

thanks. Let's see how this works in practice ;-)

forki added a commit that referenced this pull request Sep 16, 2015
Add support for custom internet proxy credentials with env vars
@forki forki merged commit cfe24a4 into fsprojects:master Sep 16, 2015
@forki
Copy link
Member

forki commented Sep 16, 2015

I guess we could need some docs for this.

@dedale
Copy link
Contributor Author

dedale commented Sep 16, 2015

Sure! I guess you're talking about http://fsprojects.github.io/.
Where do you think the docs can be added?
In the FAQ? e.g. How to use Paket behind an internet proxy?
In the Documentation section? (adding a topic Internet Proxy support)

@forki
Copy link
Member

forki commented Sep 16, 2015

A faq entry would be a good start. Please also tell something about the
default behavior.
On Sep 16, 2015 10:46 AM, "Vianney P." notifications@github.com wrote:

Sure! I guess you're talking about http://fsprojects.github.io/.
Where do you think the docs can be added?
In the FAQ? e.g. How to use Paket behind an internet proxy?
In the Documentation section? (adding a topic Internet Proxy support)


Reply to this email directly or view it on GitHub
#1061 (comment).

@dedale
Copy link
Contributor Author

dedale commented Sep 16, 2015

OK will do :-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants