Hello,

I have problems getting my second antrun target to run.

Below is the plugin configuration I use. Its purpose is to start an Apache
httpd server before integration tests and kill it later. The executables
and folders are set profile and os specific. The first execution I can see
in the maven log, and in target/antrun there is a build-main.xml created
that matches the target of the first execution. However the second
execution never appears in the log nor is a file created for it. What am I
missing here?

Cheers,
Kai

http://pastebin.com/JhpA0vaY


   1.             <plugin>
   2.                 <artifactId>maven-antrun-plugin</artifactId>
   3.                 <version>1.7</version>
   4.                 <executions>
   5.                     <execution>
   6.                         <id>Starting Apache</id>
   7.                         <phase>pre-integration-test</phase>
   8.                         <goals>
   9.                             <goal>run</goal>
   10.                         </goals>
   11.                         <configuration>
   12.                             <target name="Starting Apache">
   13.                                 <echo>Starting Apache httpd:</echo>
   14.                                 <exec executable=
   "${apache.home}/${apache.executable}" spawn="true">
   15.                                     <arg value="-f" />
   16.                                     <arg value=
   "${project.build.directory}/httpd.conf" />
   17.                                 </exec>
   18.                             </target>
   19.                         </configuration>
   20.                     </execution>
   21.                     <execution>
   22.                         <id>Stopping Apache</id>
   23.                         <phase>post-integration-test</phase>
   24.                         <goals>
   25.                             <goal>run</goal>
   26.                         </goals>
   27.                         <configuration>
   28.                             <target name="Stopping Apache">
   29.                                 <echo>Stopping Apache httpd:</echo>
   30.                                 <loadfile property="PID" srcFile=
   "${project.build.directory}/httpd.pid" />
   31.                                 <exec executable="${kill.executable}"
    failonerror="true">
   32.                                     <arg value="${kill.arguments}" />
   33.                                     <arg value="${PID}" />
   34.                                 </exec>
   35.                             </target>
   36.                         </configuration>
   37.                     </execution>
   38.                 </executions>
   39.             </plugin>
   *
   *

Reply via email to