How can I configure my web application for deployment in Tomcat so that Tomcat Manager shows the version in the table that lists all applications installed (/manager/html/list)?
Currently it shows "None Specified" for all apps, including itself. I am using Tomcat 7.0.11.
With maven set the output war file name:
Output -> MyTest##0.0.1.war
Or simple rename war-file with format file_name##version.war ;)
I am running
Tomcat 8.0.30
and to add a version in Tomcat Web Application Manager one can simply rename MyApp (under webapps folder) toMyApp##1.0.2
without creating.war
file.If you want to create
.war
file, follow these steps:jar cvf MyApp.war .
Here MyApp is name of Application,
.war
is the extension for creating war file (also called as Web Application Archive) and . represents current directory where war file will be created..After doing this, you'll see
MyApp.war
file under webapps. Now just rename toMyApp##1.0.2.war
and the server will automatically reload the context with name.That's it!
The version is the one specified when deploying the application through the manager.
See the documentation:
Also, you can deploy multiple versions of the same war by adding the version after ## (e.g. myApp##1.0.war, myApp##1.1.war). The manager will show this version in the overview.
For maven, use the tomcat plugin configuration path :
finalName trick didn't worked for me.
Referred to Apache Documentation, I tried to deploy war file manually and it works.
I do not understand why it does not work with maven tomcat deploy