To install Jetty in Linux (RedHat5.8), you must first install JDK.
Install Jetty in Linux (RedHat 5.8)
Install JDK first.
Download jetty installation package http://dist.codehaus.org/jetty/
I downloaded 8.1.15.
Tar-xzvf * .tar.gz
After decompression, you can use it.
Some demo war packages in webapps
Start the jetty service: java-jar start. jar default port 8080
Access http: // localhost: 8080.
Deploy your own war package now
You already have a war package named abc. war.
Put the war package under webapps.
Restart jetty
Access http: // localhost: 8080/abc.
If your war package name is complex and you do not want to modify it, but you want to make the access path simple
You can copy test. xml in the context directory to XXX. xml and modify the file content.
/Hello
/Webapps/abc-123-def-567.war
True
False
/Etc/webdefault. xml
At this time, you can see that the war package name is complex, but the access path has been changed to hello.
So now restart the jetty service and access http: // localhost: 8080/hello.
So far, jetty's installation and simple use are over!
Use Jetty as an Embedded Server http://www.linuxidc.com/Linux/2013-07/86983.htm
Jetty source code analysis http://www.linuxidc.com/Linux/2013-10/90986.htm
Jetty install learn and present http://www.linuxidc.com/Linux/2014-05/101993.htm
Jetty installation http://www.linuxidc.com/Linux/2013-10/90991.htm in Eclipse
For more information about RedHat, see RedHat topic page http://www.linuxidc.com/topicnews.aspx? Tid = 10
This article permanently updates the link address: Http://www.linuxidc.com/Linux/2014-10/108342.htm