【发布时间】:2014-08-28 12:35:17
【问题描述】:
我的应用程序在我的 localhost 上的 URL 上运行,即http://localhost:8080/WebIntegrationApp。
有没有办法在 pom.xml 文件中用http://WebIntegrationApp 替换http://localhost:8080/WebIntegrationApp url。
我的意思是我想使用 url http://WebIntegrationApp 运行这个应用程序。
使用的操作系统是windows7,这里是用于localhost运行tomcat的插件:
<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>localhost</server>
<path>/WebIntegrationApp</path>
<username>admin</username>
<password>s3cret</password>
</configuration>
<executions>
<execution>
<id>tomcat-run</id>
<goals>
<goal>run-war-only</goal>
</goals>
<phase>pre-integration-test</phase>
<configuration>
<fork>true</fork>
</configuration>
</execution>
<execution>
<id>tomcat-shutdown</id>
<goals>
<goal>shutdown</goal>
</goals>
<phase>post-integration-test</phase>
</execution>
</executions>
</plugin>
【问题讨论】:
标签: java maven maven-2 maven-tomcat-plugin