1

I have VPS and it already has apache and php sites running.

Now i am building project on local PC using eclispe by using Run on server without maven.

Now if i want to show that to my client , i wannt to put on live server.

SO what things i need to install and how can i copy java files there

1 Answers1

0

You need a servlet container/Java EE -server to run the web application, for example Tomcat. It's fairly easy to setup (The Tomcat-pages have instructions for Windows and Linux/Unix), once you have your server up and running, you copy your application as a .war-file into the servers' webapps-directory, Tomcat will pick it up (when it's running), deploy it and start running the application.

You get the .war-file (check that your projects' pom.xml has the packaging set to <packaging>war</packaging>) from your project by running mvn package (in Eclipse, click project root with the right mouse button, select Run as... -> Maven package). The .war-file will appear under the target-directory of the project.

esaj
  • 15,369
  • 4
  • 35
  • 52
  • I don't have j2ee sdk installed as well , how can i install that i mean in which directory –  Feb 24 '11 at 10:46
  • Sorry, looks like I understood your question wrong (you aren't using maven). Anyway, hope you got your answer in your other question (http://stackoverflow.com/questions/5108019/how-to-make-war-file-in-eclipse) and it looks like you've already found the way to get the jdk installed (http://stackoverflow.com/questions/5104817/how-to-install-java-sdk-on-centos). – esaj Feb 24 '11 at 19:56