[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [virgo-dev] How to build virgo behind proxy ?

Thanks Hristo. We are currently working on getting the s3 support to work in the Hudson build server, which is now behind a proxy, so that's useful.

Regards,
Glyn

On 13 Sep 2010, at 16:27, Iliev, Hristo wrote:

> Hi,
> 
> Here is my experience with pretty restrictive proxies (only port 80 and 8080 open). For building Virgo or running tests you can use the steps below. This short guide is for Windows although it is applicable to other OS as well with small modifications (no Cygwin).
> 
> 1.	Install Cygwin and select GIT packages
> 2.	Start Cygwin shell and set proxy:
> 
> $ export http_proxy=proxy:8080
> 
> 3.	Go to the folder which contains your repositories (D:/virgo) for instance
> 4.	Clone GIT repository:
> 
> $ git clone http://git.eclipse.org/gitroot/virgo/org.eclipse.virgo.kernel.git
> 
> 5.	Init the build submodule:
> 
> $ git submodule update --init
> 
> 6.	Submodule init will fail because it tries to access repository with git:// protocol
> 7.	Open org.eclipse.virgo.kernel/.git/config and replace git:// with http://
> 
> [submodule "virgo-build"]
> 	url = http://git.eclipse.org/gitroot/virgo/org.eclipse.virgo.virgo-build.git
> 
> 8.	The IVY will fail to find artefacts due to lack of s3:// protocol support. Change org.eclipse.virgo.kernel\virgo-build\common\ivysettings.xml and replace s3:// with http://
> 
> <macrodef name="s3repo">
> 	<attribute name="bucket"/>
> 	<attribute name="artifact.type"/>
> 	<attribute name="release.type"/>
> 	<s3 descriptor="required" accessKey="${accessKey}" secretKey="${secretKey}">
> 		<ivy pattern="http://@{bucket}/ivy/@{artifact.type}/@{release.type}/[organisation]/[module]/[revision]/[artifact]-[revision].[ext]"/>
> 		<artifact pattern="http://@{bucket}/ivy/@{artifact.type}/@{release.type}/[organisation]/[module]/[revision]/[artifact]-[revision].[ext]"/>
> 	</s3>
> </macrodef>	
> 
> 9.	jets3t library will fail to resolve hostnames - no proxy is set. Change org.eclipse.virgo.kernel\virgo-build\lib\ivy\jets3t.properties:
> 
> #httpclient.proxy-autodetect=true
> httpclient.proxy-autodetect=false
> httpclient.proxy-host=proxy
> httpclient.proxy-port=8080
> 
> Note that commenting out the autodetect property does not disable it so "false" is really needed.
> 
> 10.	Run build/tests
> 
> Regards,
> Hristo Iliev
> 
> -----Original Message-----
> From: virgo-dev-bounces@xxxxxxxxxxx [mailto:virgo-dev-bounces@xxxxxxxxxxx] On Behalf Of Glyn Normington
> Sent: Monday, September 06, 2010 11:17 AM
> To: Virgo Project
> Subject: Re: [virgo-dev] How to build virgo behind proxy ?
> 
> Thanks Olivier. (Sorry for the late reply - email backlog.)
> 
> Glyn
> On 31 Aug 2010, at 15:01, Olivier Girardot wrote:
> 
> Hi Glyn,
> So first of all due to a proxy configuration i couldn't use the git:// url :
> 
> D:\private>git clone git://git.eclipse.org/gitroot/virgo/org.eclipse.virgo.kernel.git<http://git.eclipse.org/gitroot/virgo/org.eclipse.virgo.kernel.git>
> Initialized empty Git repository in D:/private/org.eclipse.virgo.kernel/.git/
> fatal: Unable to look up git.eclipse.org<http://git.eclipse.org/> (port 9418) (No such host is known. )
> 
> So i use the following URL : git clone http://git.eclipse.org/gitroot/virgo/org.eclipse.virgo.kernel.git
> in order to be able to clone the kernel module. But the command git submodule update --init
> Failed because of the "git://" url,
> so i changed to default url into git's file : .gitmodules to
> url = http://git.eclipse.org/gitroot/virgo/org.eclipse.virgo.virgo-build.git
> and as there was a creation of the submodule reference in file .git/config, you need to change the url in this file too
> Then you need to have ant into your Path, and when i tried, to build using goals clean, clean-integration test :
> i got this due to my proxy :
> [ivy:cachepath]                 ::::::::::::::::::::::::::::::::::::::::::::::
> [ivy:cachepath]                 ::          UNRESOLVED DEPENDENCIES         ::
> [ivy:cachepath]                 ::::::::::::::::::::::::::::::::::::::::::::::
> [ivy:cachepath]                 :: org.springframework.build#org.springframework.build.ant;1.1.0.RELEASE: not found
> [ivy:cachepath]                 ::::::::::::::::::::::::::::::::::::::::::::::
> 
> To resolve this the command -autoproxy  didn't work, but setting explicitely the env variable :
> set ANT_OPTS=-Dhttp.proxyPort=8080 -Dhttp.proxyHost=myProxyHost -Dhttp.proxyUser=myUser -Dhttp.proxyPassword=myPassword
> worked for me,
> 
> Hope it will help somebody,
> Regards,
> 
> Olivier.
> 2010/8/31 Glyn Normington <gnormington@xxxxxxxxxx<mailto:gnormington@xxxxxxxxxx>>
> Hi Olivier
> 
> Please could you describe in detail what you did to get this working as I'm sure others will benefit from the information.
> 
> Also we face possibly the same issue on the new Eclipse CI server, so the detail would save us committers some time too.
> 
> Thanks,
> Glyn
> On 13 Aug 2010, at 15:55, Olivier Girardot wrote:
> 
> Thank you it didn't work (using autoproxy) but using explicit env variable
> it worked like a charm
> 
> Regards,
> Olivier.
> 
> 2010/8/12 Iliev, Hristo <hristo.iliev@xxxxxxx<mailto:hristo.iliev@xxxxxxx><mailto:hristo.iliev@xxxxxxx<mailto:hristo.iliev@xxxxxxx>>>
> Hi,
> 
> There is nice proxy guide for ANT here:
> http://ant.apache.org/manual/proxy.html
> 
> I guess the "-autoproxy" would be the easiest way...
> 
> Regards,
> Hristo
> 
> From: virgo-dev-bounces@xxxxxxxxxxx<mailto:virgo-dev-bounces@xxxxxxxxxxx><mailto:virgo-dev-bounces@xxxxxxxxxxx<mailto:virgo-dev-bounces@xxxxxxxxxxx>> [mailto:virgo-dev-bounces@xxxxxxxxxxx<mailto:virgo-dev-bounces@xxxxxxxxxxx><mailto:virgo-dev-bounces@xxxxxxxxxxx<mailto:virgo-dev-bounces@xxxxxxxxxxx>>] On Behalf Of Olivier Girardot
> Sent: Thursday, August 12, 2010 4:51 PM
> To: virgo-dev@xxxxxxxxxxx<mailto:virgo-dev@xxxxxxxxxxx><mailto:virgo-dev@xxxxxxxxxxx<mailto:virgo-dev@xxxxxxxxxxx>>
> Subject: [virgo-dev] How to build virgo behind proxy ?
> 
> Hi everyone,
> i wanted to know how i could build virgo repositories behind a proxy ?
> I got git working and cloned kernel repo + submodule (build-kernel), but now as i'm starting to build the project with ant ,
> it has some problem downloading dependencies.
> Where can i tweak the ant tasks to use a dedicated proxy ?
> 
> Thank you,
> 
> Regards,
> 
> Olivier.
> 
> _______________________________________________
> virgo-dev mailing list
> virgo-dev@xxxxxxxxxxx<mailto:virgo-dev@xxxxxxxxxxx><mailto:virgo-dev@xxxxxxxxxxx<mailto:virgo-dev@xxxxxxxxxxx>>
> https://dev.eclipse.org/mailman/listinfo/virgo-dev
> 
> 
> <ATT00001..txt>
> 
> _______________________________________________
> virgo-dev mailing list
> virgo-dev@xxxxxxxxxxx<mailto:virgo-dev@xxxxxxxxxxx>
> https://dev.eclipse.org/mailman/listinfo/virgo-dev
> 
> <ATT00001..txt>
> 
> _______________________________________________
> virgo-dev mailing list
> virgo-dev@xxxxxxxxxxx
> https://dev.eclipse.org/mailman/listinfo/virgo-dev
> _______________________________________________
> virgo-dev mailing list
> virgo-dev@xxxxxxxxxxx
> https://dev.eclipse.org/mailman/listinfo/virgo-dev