[opensuse-buildservice] How to access OBS from behind a proxy (used to work)?
Hi, since a few weeks (2-3 weeks), I'm not able to access the OBS from behind a proxy. This used to work with the setup described in this email: http://lists.opensuse.org/opensuse-buildservice/2007-04/msg00016.html I had a look at theOBS CLI migration page: http://en.opensuse.org/Build_Service/CLI#Configuration_migration But from that I did not get the hint that makes it work for me. (it looks like that it is not possible to specify the port number) The result is: home:rbos> osc ls openSUSE_11.2 i586 home:rbos SSL Error: unexpected eof At the moment my .oscrc contains: home:rbos> cat ~/.oscrc [DEFAULT] [general] apiurl=https://api.opensuse.org:9999 [https://api.opensuse.org:9999] user=<login> passx=<password> What's needed to access OBS again from behind proxy?? -- Richard -- To unsubscribe, e-mail: opensuse-buildservice+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-buildservice+help@opensuse.org
On 3/18/2010 at 9:42, Richard Bos
wrote: Hi, since a few weeks (2-3 weeks), I'm not able to access the OBS from behind a proxy. This used to work with the setup described in this email: http://lists.opensuse.org/opensuse-buildservice/2007-04/msg00016.html
I had a look at theOBS CLI migration page: http://en.opensuse.org/Build_Service/CLI#Configuration_migration But from that I did not get the hint that makes it work for me. (it looks like that it is not possible to specify the port number)
The result is: home:rbos> osc ls openSUSE_11.2 i586 home:rbos SSL Error: unexpected eof
At the moment my .oscrc contains: home:rbos> cat ~/.oscrc [DEFAULT]
[general] apiurl=https://api.opensuse.org:9999
[https://api.opensuse.org:9999] user=<login> passx=<password>
What's needed to access OBS again from behind proxy??
Those entire workaround things are no longer needed if you run a recent enough python and urllib2 (python 2.6 is what is checked in osc). At very first I had to change my conf.py (as python got updated before osc new about it)... check conf.py in the osc installation folder (you can easily find it using rpm -ql osc) and search for "if 'https_proxy' in os.environ:" . In older versions of osc this was unconditionally done... latest ones do it only with python < 2.6. If it's unconditional in your version, you should either: a) upgrade osc. You will love it b) comment out the deletion of the environment variable. In both cases (again: with python 2.6 running), you can do: export http_proxy=http://ip.proxy.com:3128 export https_proxy=$http_proxy I use this almost daily for a few weeks without issues. (I'm still missing support for pac files... but that has to be hacked in urllib2, which has a very bad structure to put anything alike in...) Dominique -- To unsubscribe, e-mail: opensuse-buildservice+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-buildservice+help@opensuse.org
On Thu, Mar 18, 2010 at 09:52:44AM +0100, Dominique Leuenberger wrote:
On 3/18/2010 at 9:42, Richard Bos
wrote: What's needed to access OBS again from behind proxy?? Those entire workaround things are no longer needed if you run a recent enough python and urllib2 (python 2.6 is what is checked in osc). At very first I had to change my conf.py (as python got updated before osc new about it)... check conf.py in the osc installation folder (you can easily find it using rpm -ql osc) and search for "if 'https_proxy' in os.environ:" . In older versions of osc this was unconditionally done... latest ones do it only with python < 2.6. If it's unconditional in your version, you should either: a) upgrade osc. You will love it b) comment out the deletion of the environment variable.
In both cases (again: with python 2.6 running), you can do:
export http_proxy=http://ip.proxy.com:3128 export https_proxy=$http_proxy
Thanks, this (the export of variables) made it work. I had to change the url in the file $PWD/.osc/_apiurl to make it work completely. -- Richard -- To unsubscribe, e-mail: opensuse-buildservice+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-buildservice+help@opensuse.org
participants (2)
-
Dominique Leuenberger
-
Richard Bos