Jetty9.4.5 Installing deployment documentation

jetty9.4.5 Installation and Deployment Document


1. Download the installation package

 wget http://central.maven.org/maven2/org/eclipse/jetty/jetty-distribution/9.4.5.v20170502/jetty-distribution-9.4.5.v20170502.tar.gz

2. Unzip and install

tar xzvf jetty-distribution-9.4.5.v20170502.tar.gz
mv jetty-distribution-9.4.5.v20170502 jetty-9.4. 5

3. Modify port

vim jetty-9.4.5/start.ini

Find jetty.http.port=8080, modify it to the port you need

4.Deploy war package

cd jetty-9.4. 5/webapps

Create a new fb_service.xml in the webapps directory, the content of the file is as follows





/
/path/to/ app.war

Modify the war parameter to the real war package path

resourceBase is the parameter of the deployment directory

5. Start/stop/restart jetty

cd jetty-9.4.5/bin
./jetty.sh start
./jetty.sh stop
./jetty.sh restart
./jetty.sh status
./jetty.sh run

additional instructions

1. Install multiple jetty runs , You need to add JETTY_HOME and JETTY_RUN configuration in front of each jetty’s jetty.sh

JETTY_HOME=/data/jetty-9.4.5
JETTY_RUN=/data/jetty-9.4.5

2. Turn on jetty’s remote debugging function and add the following configuration in front of jetty.sh

if ["run" = $1 ]; then
JAVA_OPTIONS+=("-Xdebug -Xrunjdwp :server=y,transport=dt_socket,address=8000,suspend=y")
fi

Then run ./jetty.sh run to start remote Debug

Leave a Comment

Your email address will not be published.