I have recently created a web application using spring mvc, gradle and tomcat to host it. I have been trying to create a war file of the web application which can be executed on its own with no need to have gradle and tomcat installed on your computer.
For example running java -jar <path-to-war>
and the server will be running on the localhost port specified.
What is the best way to approach this?
use spring boot, comes with embedded tomcat,include below in pom and
Main method