Error 404 when I try to deploy my war on Jetty on Debian 9

天涯浪子 提交于 2019-12-11 17:31:42

问题


I'm trying to deploy my java web site on a Debian online server. For that, I install Jetty (following this : http://zetcode.com/java/jetty/install/)

Jetty seems to be ok on the server because when I enter http://myipaddress:8080. I have the "Welcome to Jetty".

Then, I use Filezilla to upload my war on the server. I compile my war with Eclipse and Maven :

<groupId>com.example</groupId>
<artifactId>test</artifactId>
<packaging>war</packaging>
<version>1.0-SNAPSHOT</version>
<name>test</name>

I compile it with mvn clean package. I had my war file. And I put it on the server :

I tried to put it in opt/jetty/webapps and opt/web/mam/webapps

But when I tried to access to my web site by doing http://myipaddress/test, I received a 404 error.

And I tried my command line with the curl command, I received an 404 error too.

I know it's basic, but I'm blocked..

How can I be sure that my war is ok? How can I be sure that my jetty configuration is ok?

Thanks


回答1:


I fixed it by deleting the jetty installation and reinstall it. I put my WAR in the opt/jetty/webapps.



来源:https://stackoverflow.com/questions/45848086/error-404-when-i-try-to-deploy-my-war-on-jetty-on-debian-9

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!