On Wed, Jun 16, 2010 at 6:25 PM, Scott Henson <shenson(a)redhat.com> wrote:
On Tue, 15 Jun 2010 19:39:04 -0300, Nicolás Pace
<nicopace(a)gmail.com> wrote:
> Hi people,
> I found out that cobbler-ext-nodes is ignoring the no_proxy
> environment variable.
> I need cobbler-ext-nodes to ignore http_proxy, or to pay attention to
> no_proxy, in order to fetch data from the local network and not from
> the server.
>
> I've seen that cobbler-ext-nodes is using urlgrabber to fetch this
> info, and that's why it is not using no_proxy (it is an old bug in
> urlgrabber that didn't seem to be patched yet :S).
I don't think there is much we can do here. I'd file a bug against
urlgrabber and ask if they could fix it. I don't really want to get in
the business of working around broken code that we use. If you know of
a better library and want to provide a patch, I'd be happy to accept
it. Beyond that, I'm not sure what else we could do.
Couldn't just use another way to fetch that info?
I tried with urllib and urllib2, and both of them are having problems
with this thing.
wget is inmune to this problem :D, so we could replace the line:
" print urlgrabber.urlread(url)"
with
print commands.getstatusoutput('wget' + url + '-O- 2>/dev/null')
Regards,
--
Ing. Nicolás Pace
http://www.linkedin.com/in/nickar/
http://www.jornadasdelsur.org.ar/