2010-12-29 8 views
2

Ich benutze maven2. Ich habe tomcat7 installiert. Ich möchte das Plugin so konfigurieren, dass es tomcat7 verwendet, das installiert ist. kann jemand auf einen Link verweisen, der dies tut.maven remote tomcat konfiguration

Antwort

4

Verwenden Sie Cargo-Plugin für diese. Konfigurieren Ladung so etwas wie dieses

 <profiles> 
      <profile> 
       <id>integration</id> 
       <build> 
        <plugins> 
         <plugin> 
         <groupId>org.codehaus.cargo</groupId> 
         <artifactId>cargo-maven2-plugin</artifactId> 
         <version>1.0</version> 
         <configuration> 
          <!-- Container configuration --> 
          <container> 
          <containerId>tomcat6x</containerId> 
          </container> 
          <configuration> 
          <type>existing</type> 
          <home>/usr/local/apache-tomcat-6.0.18</home> 
          </configuration> 
         </configuration> 
         </plugin> 
        </plugins> 
       </build> 
      </profile> 
     </profiles> 

ich gleiche Setup haben, aber ich habe diese getestet auf Tomcat6.0.x und Jetty 7.0.16. Diese Links helfen


für Remote-Bereitstellung Verwendung so (nicht unterschiedlich sein müssen in tomcat7)

 <configuration> 
     <!-- Container configuration --> 
     <container> 
      <containerId>tomcat6x</containerId> 
      <type>remote</type> 
     </container> 
     <configuration>   
      <type>runtime</type> 
      <properties> 
       <cargo.remote.username>admin</cargo.remote.username> 
       <cargo.remote.password></cargo.remote.password> 
       <cargo.tomcat.manager.url>http://localhost:8888/manager</cargo.tomcat.manager.url> 
      </properties> 
     </configuration> 
     ... 
    </configuration> 

Auch die beziehen Links oben!