开发者

How to make spring mvc project live on linux server

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


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.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜