【发布时间】:2018-09-19 07:11:40
【问题描述】:
我使用 maven 的 tomcat 插件将我的 web 应用程序部署到 tomcat 服务器。现在我需要在不同的位置使用相同的war文件(不直接部署到tomcat服务器。)。这样我就可以手动将我的 war 文件复制到另一台机器上并部署它。
我当前的 pom.xml 配置是
<profiles>
<profile>
<id>staging</id>
<build>
<pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.tomcat.maven</groupId>
<artifactId>tomcat7-maven-plugin</artifactId>
<version>2.2</version>
<configuration>
<url>http://localhost:8080/manager/text</url>
<server>mytomcat</server>
<path>/project1</path>
<username>xxxxxxx</username>
<password>xxxxxxxx</password>
</configuration>
</plugin>
</plugins>
</pluginManagement>
</build>
</profile>
【问题讨论】:
-
你能实现这个还是需要更多帮助?
标签: spring-boot maven-plugin maven-tomcat-plugin