开发者

Best practice on how to configure two local maven directories for continous integration with Hudson

I use Hudson as our build server. WE have a very large project that is devided into several maven based projects. There are several dependencies between the artifacts of these projects. Currently we don't version the code good enough so that we need two maven repositories to manage the dependencies correctly.

My question is how to setup the two local repositories? I came up with two options:

  1. I have two maven installation where each has it's own repository. In Hudson I can configure the two repositories and can choose whichever I want on the job.

  2. I have one maven installation but two different config files. In this case I need to provide which config file to use within every job. The disadvantage is, that this information is displayed only if I hid开发者_开发百科 the advanced button for the maven configuration within the job.

Are there any more options that I missed? What would you choose and why. The criteria is, that it should be easy to configure and easy to verify, even for someone who has little to no experience in configuring Hudson.


My suggestion would be to define the different repositories in different profiles either in settings.xml of the hudson server (if you dont want it in the development environment), or in a parent pom for your projects. And then activate the profile you want at build time on hudson. I am suggesting this one because it is independent of your maven installation, so you do not have to worry about your custom configs when upgrading maven...

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜