#!/usr/bin/perl
use LWP::UserAgent;
my $agent = LWP::UserAgent->new();
$agent->proxy(['http', 'https'], "http://APIKEY:@proxy.crawlera.com:8010");
print $agent->get('http://httpbin.scrapinghub.com/ip')->content();
0 Votes
3 Comments
Sorted by
thriveniposted
over 4 years ago
Admin
It seems some firewall blocking the Crawlera proxy port. Can you please check the firewalls and open the port 8010.
0 Votes
R
Rajesh Singhposted
over 4 years ago
Hi,
When I run this script from my local XP machine, it works fine but when I do the same from a remote server running on Linux, it says: 500 Can't connect to proxy.crawlera.com:8010 (connect: Connection refused).
Can you tell me what the issue could be? Thanks
0 Votes
nestorposted
about 7 years ago
AdminAnswer
This should work:
#!/usr/bin/perl
use LWP::UserAgent;
my $agent = LWP::UserAgent->new();
$agent->proxy(['http', 'https'], "http://APIKEY:@proxy.crawlera.com:8010");
print $agent->get('http://httpbin.scrapinghub.com/ip')->content();
How i can call Crawlera in PERL script
0 Votes
nestor posted about 7 years ago Admin Best Answer
This should work:
0 Votes
3 Comments
thriveni posted over 4 years ago Admin
It seems some firewall blocking the Crawlera proxy port. Can you please check the firewalls and open the port 8010.
0 Votes
Rajesh Singh posted over 4 years ago
Hi,
When I run this script from my local XP machine, it works fine but when I do the same from a remote server running on Linux, it says: 500 Can't connect to proxy.crawlera.com:8010 (connect: Connection refused).
Can you tell me what the issue could be? Thanks
0 Votes
nestor posted about 7 years ago Admin Answer
This should work:
0 Votes
Login to post a comment