Alternate port for Tomcat (not 8080) when starting with Maven?

I know this thread is old but…

The link to the documentation, provided by Greg is interesting :

port:
The port to run the Tomcat server on.
    Type: int
    Required: No
    Expression: ${maven.tomcat.port}
    Default: 8080

The expression is what maven use to get the value in its code. It could come from a configuration file, or from the command line.

You could run

mvn -Dmaven.tomcat.port=8181 tomcat:run-war

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)