I’ve taken a checkout of a project on github from below…
https://github.com/wakaleo/game-of-life/
I can build it and create a war file. The only problem I have is that when I make the war in /gameoflife/target/gameoflife.war when I right click on it, I don’t get the option to “run on server”.
I’ve created a tomcat server, how do I actually configure the project to allow me to run this war on a tomcat server or even associate the war file with tomcat?
I can get the project to work by just copying this war into a webapps folder on tomcat, but surely there’s a solution that can be done within my IDE so I just have to click “run”.
Thanks,
David
You have to create a server runtime in eclipse.
You just go to
Window->Preferences->Serversand add a new Runtime Environment.Choose the button create local server
Set it up to point to your Tomcat.
Then you should see a servers tab and a server view for tomcat configuration.
By clicking on the tomcat inside the server view you can select all dynamic web projects to be imported.
Or you can click on the project and add it to server
Update:
If it not a dynamic web project then you should add the relative facets.
Right-click on project and click Properties.
Click on
Project Facetsand modify your project to includeDynamic Web Moduleand all the dependencies.This should be done using
J2EEperspective