[fuel-menu] repo check failed in fuelmenu when providing as proxy: localhost
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Fuel for OpenStack |
In Progress
|
Low
|
Vitalii Kulanov |
Bug Description
probably we need somehow to catch such issues:
1) run fuelmenu
2) select bootstrap image
3) defined http proxy as localhost
4) run check on the same tab
get traceback [1]:
File "/usr/lib/
conn = self.get_
File "/usr/lib/
conn = proxy_manager.
File "/usr/lib/
u = parse_url(url)
File "/usr/lib/
raise LocationParseEr
requests.
[1] http://
fuelmenu version:
[root@fuel ~]# rpm -q --changelog fuelmenu
* Fri Feb 05 2016 Matthew Mosesohn <email address hidden> - 9.0.0-1.mos242
- 8273639 Fix literal string builder for puppet class
- f722fbd Merge "Fix return value for restore if no path provided"
- bc5bf98 Merge "Call l23network init for interface config"
- fba0825 Call l23network init for interface config
- 98d5814 Fix return value for restore if no path provided
- bdcaaca Merge "Consolidate externall shell execs"
- 0acccda Merge "Remove direct copying default settings.yaml to astute.yaml"
- d2a14d4 Consolidate externall shell execs
- 84d2e3f Merge "Change behavior in case when management interface is down"
- 8fe1220 Remove direct copying default settings.yaml to astute.yaml
Changed in fuel: | |
status: | New → Confirmed |
summary: |
- [fuel-manu] repo check failed in fuelmenu when providing as proxy: + [fuel-menu] repo check failed in fuelmenu when providing as proxy: localhost |
Changed in fuel: | |
assignee: | Fuel Python Team (fuel-python) → vkulanov (vitaliy-t) |
Changed in fuel: | |
milestone: | 9.0 → 10.0 |
In our case http:// localhost: 80 is not a valid proxy server. /github. com/openstack/ fuel-library/ commit/ d60233a0cba912f aa2170f9f897936 0ff0740c55 /bugs.launchpad .net/fuel/ +bug/1270187)
Besides that we have apache redirect to Fuel Web interface on port 80
(https:/
https:/
So if we try to use localhost as a proxy server we get url parse exception:
File "/usr/lib/ python2. 7/site- packages/ requests/ packages/ urllib3/ util/url. py", line 187, in parse_url ror(url) packages. urllib3. exceptions. LocationParseEr ror: Failed to parse: archive. ubuntu. com:8000: 8000
raise LocationParseEr
requests.
Some examples (localhost as a proxy):
[root@fuel ~]# curl -x localhost:80 -I http:// example. com /example. com:8443/
HTTP/1.1 301 Moved Permanently
Date: Wed, 02 Mar 2016 07:06:34 GMT
Server: Apache/2.4.6 (CentOS) OpenSSL/1.0.1e-fips mod_wsgi/3.4 Python/2.7.5
Location: https:/
Content-Type: text/html; charset=iso-8859-1
[root@fuel ~]# curl -x localhost:80 -I http:// example. com/test example. com:8000/ test
HTTP/1.1 301 Moved Permanently
Date: Wed, 02 Mar 2016 07:52:03 GMT
Server: Apache/2.4.6 (CentOS) OpenSSL/1.0.1e-fips mod_wsgi/3.4 Python/2.7.5
Location: http://
Content-Type: text/html; charset=iso-8859-1
[root@fuel ~]# curl -x localhost:80 -I http:// example. com:8000/ test example. com:8000:8000/test
HTTP/1.1 301 Moved Permanently
Date: Wed, 02 Mar 2016 07:54:33 GMT
Server: Apache/2.4.6 (CentOS) OpenSSL/1.0.1e-fips mod_wsgi/3.4 Python/2.7.5
Location: http://
Content-Type: text/html; charset=iso-8859-1
Example for some valid proxy:
[root@fuel ~]# curl -x 195.154.231.43:80 -I http:// example. com b1-4fa73693161c 7"
HTTP/1.1 200 OK
Date: Wed, 02 Mar 2016 08:32:25 GMT
Server: Apache/2.2.22 (Ubuntu)
Last-Modified: Wed, 28 May 2014 10:38:19 GMT
ETag: "bc0b89-
Accept-Ranges: bytes
Content-Length: 177
Vary: Accept-Encoding
Content-Type: text/html
X-Pad: avoid browser bug
So, I think that we have to add some function that will check 'validity' of proxy server
before creating any get request through.