That's not the way web apps work. Web apps are hosted remotely using an app server such as
Tomcat. They're not intended to run locally like an executable program.
That said, there's probably some way to bundle a server and web app in an executable for running locally. It's not common, and it's certainly nothing I've ever considered doing.