环境jdk1.8 tomcat7
1.pom.xml
<plugin>
<groupId>org.apache.tomcat.maven</groupId>
<artifactId>tomcat7-maven-plugin</artifactId>
<version>2.2</version>
<configuration>
<port>8080</port>
<path>/xf</path>
<url>http://ip:8080/manager/text</url>
<username>admin</username>
<password>admin</password>
</configuration>
</plugin>
2.tomcat配置
<role rolename="manager-gui" />
<role rolename="manager-script" />
<user username="admin" password="admin" roles="manager-gui, manager-script"/>