本文介绍了maven远程tomcat配置的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

限时删除!!

我正在使用maven2。我安装了tomcat7。我想配置插件以使用已安装的tomcat7。有人可以指向这样做的链接。

I am using maven2. I have tomcat7 installed. I want to configure the plugin to use tomcat7 that is installed. can somebody point to a link that does this.

推荐答案

使用Cargo插件。配置这样的货物

Use Cargo plugin for this. Configure cargo something like this

        <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>

我有相同的设置,但我在Tomcat6.0.x和Jetty 7.0.16上测试了这个。这些链接将有所帮助

I have same setup, but I have tested this on Tomcat6.0.x and Jetty 7.0.16. These links will help




  • Automated deploy with Cargo
  • Cargo config for Tomcat 7

用于远程部署像这样使用(在Tomcat7中不能有所不同)

for remote deployment use like this (must not be different 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>

再次参考上面的链接!

这篇关于maven远程tomcat配置的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

1403页,肝出来的..

09-08 06:15