Skip to main content
Bartlomiej
Gold ⭐️
Oct 1, 2024 12:25 PM UTC
Question

How to use proxy server while importing python libraries that need internat access in HUE or Zeppelin

Dear Freinds

My Cloudera Cluster has no access to the internet - if I need to gather some parcel or any file via wget for example

 

But what if I want to import some python library in HUE or Zeppelin that requires dynamic access to the internet.

I have installed via pop3 pgeocode library and now in Peppelin or HUE when I want to dynamically call that library I am getting TIme OUT issue  :

 

File "/usr/lib64/python3.9/urllib/request.py", line 1349, in do_open
raise URLError(err)
urllib.error.URLError: <urlopen error [Errno 110] Connection timed out

How can I use proxy server in such cases so HUE or Zeppelin if record has access to the internet - able to reach the python library modules.

2 replies

Bartlomiej
Gold ⭐️
Oct 1, 2024 12:38 PM UTC

For exampale 

When  I run via HUE

import pgeocode

dist = pgeocode.GeoDistance('pl')

I got the Error - Time Out as i cannot access the Internet and need to go via proxy - but how this proxy can be configured in Hue or be part of the code in HUE

Translate
DianaTorres
Community Manager
Community Manager
Oct 4, 2024 6:30 PM UTC

Hi! @dturnau @jrm @nramanaiah Do you have some insights here? Thanks!

Translate
Regards, Diana Torres, Senior Community Moderator