Java EE – MVN Tomcat: run – change the default Maven Tomcat port
•
Java
Try following my spring roo tutorial steps:
$mkdir sample $cd sample $roo roo> script --file filename.roo roo> quit $mvn tomcat:run
When I start MVN Tomcat: run my suspend console on info: start Coyote http / 1.1 on http-8080 because this port is busy Where can I change port 8080 to another (I tried to change the Tomcat port, but I didn't find anything in Maven folder,. M2 folder and project folder)? Thank you in advance for any help
Solution
You can use:
mvn tomcat:run -Dmaven.tomcat.port=8081
Start it on a different port (8081 in this case)
Alternatively, define a plugin mangement section in your POM to configure the "port" configuration on the Tomcat plug-in
The content of this article comes from the network collection of netizens. It is used as a learning reference. The copyright belongs to the original author.
THE END
二维码