Bug 1398976

Summary: otopi-plugins/otopi/packagers/yumpackager.py seems to ignore YUM 'proxy' option
Product: [oVirt] otopi Reporter: Jiri Belka <jbelka>
Component: Plugins.packagersAssignee: Yedidyah Bar David <didi>
Status: CLOSED WORKSFORME QA Contact: Pavel Stehlik <pstehlik>
Severity: low Docs Contact:
Priority: unspecified    
Version: 1.5.2CC: bugs, jbelka, oourfali
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-12-12 10:38:27 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: Node RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Jiri Belka 2016-11-27 19:43:10 UTC
Description of problem:

otopi-plugins/otopi/packagers/yumpackager.py seems to ignore YUM 'proxy' option, thus downloading rpms won't be cached by http proxy.

Version-Release number of selected component (if applicable):
1.5.2-1.el7

How reproducible:
100%

Steps to Reproduce:
1. install RHVH
2. modify /etc/yum.conf - add 'proxy=$url' (have a working http proxy)
3. click Upgrade from Admin Portal

Actual results:
http proxy won't get any connection from host, so it seems python yum code does ignore YUM proxy option

Expected results:
it should use proxy defined in yum.conf

Additional info:
it does not matter if RHVH is not keeping config changes, it was just discovered on RHEVH. and there's a WIP to have a possibility to keep configuration changes on RHEVH.

Comment 1 Jiri Belka 2016-11-29 08:38:58 UTC
Please wait with work on this, it was discovered that our squid was in trouble. I'll either confirm this issue or close it as PEBKAC.

Comment 2 Yedidyah Bar David 2016-11-29 10:50:46 UTC
Noting that this works for me routinely.

A specific flow fails for me with dnf packager, see bug 1392312. Still not sure about it, but if you reproduce, please update that bug.

Also, yum and dnf behave differently when passing a URL:

{yum|dnf} install http://host/path/to/package.rpm

yum works well (meaning, tries to fetch the package through the proxy configured in yum.conf)

dnf didn't work well for me when Tried this, but did work when setting http_proxy in its environment. Didn't yet fully investigate nor opened a bug (or searched for an existing one).

Last point is unrelated to otopi, but perhaps a fix for it will also fix bug 1392312, not sure.

Comment 3 Jiri Belka 2016-12-12 10:38:27 UTC
PEBKAC issue.