本来以为使用CruiseControl的话,编写config.xml就可以了,但是使用中发现,如果想看到正确的results jsp,还是需要修改cruisecontrol目录下/webapps/cruisecontrol/WEB-INF/web.xml文件。
主要是log的目录和ArtifactServlet中root的目录,如下红字部分:
<context-param>
<!-- You can set this value via the user.log.dir property in Ant, when building the WAR file. -->
<param-name>logDir</param-name>
<param-value>C:/CruiseControlBuild/logs</param-value>
<description> This should be the full path to your CruiseControl log directory. If you
are in single project mode, this will contain only the logs for your project. If you
are in multi-project mode, it is expected that you will have multiple sub-directories
inside this log directory, one for each project.
</description>
</context-param>
<servlet>
<servlet-name>ArtifactServlet</servlet-name>
<servlet-class>net.sourceforge.cruisecontrol.servlet.FileServlet</servlet-class>
<init-param>
<param-name>rootDir</param-name>
<param-value>C:/CruiseControlBuild/artifacts</param-value>
</init-param>
</servlet>