Skip to content
This repository was archived by the owner on May 30, 2023. It is now read-only.

proxy exceptions #12863

Closed
wants to merge 1 commit into from
Closed

Conversation

jefleponot
Copy link

#12131

add a new command line option : --no-proxy
to filter proxy exceptions

it compiles and works well to me :-)

Can you help me to complete tests files ?
Cu everybody

@gaje
Copy link

gaje commented Jan 12, 2015

Do you have a stable build that includes the --no-proxy proxy exceptions that you can send me? I compiled the source code from your fork, which compiled successfully, but upon running phantom crashes immediately.

@jefleponot
Copy link
Author

Hi gaje,

I used my phantom fork on ubuntu 14.04 x86_64 and Centos 5.6 x86_64 to supervise web sites.
No crashed occurs.

Regards

@zackw
Copy link
Contributor

zackw commented Dec 22, 2015

We apologize for ignoring this PR for nearly a year.

I don't understand what you mean by "add a new command line option --no-proxy to filter proxy exceptions", and the code doesn't clarify matters enough for me to be sure. Could you please try again to explain the new feature?

@zackw zackw mentioned this pull request Dec 22, 2015
@gabel
Copy link

gabel commented Feb 22, 2016

@zackw Any chances this will be resolved? Is a new PR needed?

--no-proxy should exclude all domains/ips listed from being connected via proxy and fetch them directly

@vurral
Copy link

vurral commented Feb 22, 2016

@zackw Have you seen the issue #12131? The discussion over there clarified this pull request for me.

@vitallium
Copy link
Collaborator

We already have WebPage::setProxy method. I suggest to change it to accept an empty string that clears the proxy for the web page.

@gabel
Copy link

gabel commented Feb 22, 2016

I need it for a behat > selenium > phantomjs workflow and this for in the phantomjs cli.

@vitallium vitallium force-pushed the master branch 2 times, most recently from 1842ba8 to 842715b Compare March 15, 2016 17:40
@gabel
Copy link

gabel commented Mar 16, 2016

@zackw Any news to accept this? Any infos needed? Should this PR be refactored?

@jefleponot
Copy link
Author

Hi @gabel , @vitallium , @kramsee , @zackw , @gaje

This feature was important for me with phantom 1.9.7 because many of web Intranet appliances (direct access) required Internet Data geolocation (proxies configuration)

So I need the same features that a real web browser (graphic browser that means) , more than WebPage::setProxy . Can you filter each url in using setProxy on request event (very user-friendly) ?

capture du 2016-03-17 09 03 45

Fortunately, phantomJS 2.1.1 use environment variables on Linux so I didn't have to use my PR any more with this workaround just using :

  • http_proxy=...
  • https_proxy=...
  • no_proxy=...

I don't know about windows environment variables.

Best Regards
jef

@gabel
Copy link

gabel commented Apr 19, 2016

@jefleponot thx for the information, i'm going to check the environment no_proxy option with phantomJS 2.1.1 -- lets pray it works...

@vitallium vitallium force-pushed the master branch 2 times, most recently from e024f31 to 5d99f2a Compare May 19, 2016 20:53
@EugenioLaghi
Copy link

Any news on this feature?

@gabel
Copy link

gabel commented Jun 30, 2016

@EugenioLaghi After switching to phantomJS >= 2.1.1 the environmental bash/sh variable no_proxy works finally. So from my point of view this feature is not required anymore.

@petestorey26
Copy link

The environment variable doesn't do anything if you're just using PhantomJS directly - perhaps if you have some complex selenium setup it does, but if I search the source of master for PhantomJS, there is no reference to no_proxy at all :(

This feature would be very useful - to be able to not use a proxy for specific hosts, because you want to handle them separately.

@gabel
Copy link

gabel commented Mar 9, 2017

@petestorey26 I guess it's not phantomJS but a dependency. We're able to use no_proxy since 2.1.x

@petestorey26
Copy link

OK thanks, so what are you using then? Are you having something else drive phantom and provide the proxying?

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

Successfully merging this pull request may close these issues.

8 participants