【发布时间】:2016-07-11 06:21:48
【问题描述】:
我们正在处理一个遗留项目,首要任务是为其设置 DevOps。 重要的是我们对这个领域还很陌生。
我们最初计划为此目的使用 jenkins 和 sonarqube。让我从要求开始。
- 目前该项目被细分为多个项目(不是模块)
- 我们必须遵循这个构建结构,因为没有计划将其重新组织为单个多模块 maven 项目
- 目前手动管理构建和依赖项
例如:项目被细分为 5 个多模块 maven 项目, 说A,B,C,D和E
1. A and C are completely independent and can be easly built
2. B depends on the artifact generated by A (jar) and has multiple maven profiles (say tomcat and websphere, it is a webservice module)
3. D depends on the artifact generated by C
4. E depends on A, B and D and has multiple maven profiles (say tomcat and websphere, it is a web project)
根据处理这种情况的 jenkins 文档,我们正在考虑使用“参数化构建插件”和“扩展选择参数插件”的参数化构建,借助这些插件,我们能够参数化配置文件名称。但在每次构建之前,构建器等待配置文件参数。
所以我们仍在寻找一个好的解决方案
1. keep the dependency between projects an built the whole projects if there is any change in SCM (SVN). For that we are used "Build whenever a SNAPSHOT dependency is built" and "SCM polling option". Unfortunately this option seems not working in our case (we have given an interval of 5 min for scm polling but no build is happening based on test commits)
2. Even though we are able to parameterize the profile, this seems as a manual step (is there an option to automate this part too, ie. build with tomcat profile and websphere profile should happen sequentially).
我们正在努力寻找满足所有这些核心要求的解决方案。任何指针将不胜感激。
谢谢, 圣
【问题讨论】:
标签: java maven jenkins build devops