Jetty Debian Packages
Packages and Installation Order
Having downloaded all of the jetty debian packages, you should install them using dpkg or synaptic or your favourite package installer in this order, where <version> is replaced by the version of jetty you want to install:
- libjetty6-java_<version>_all.deb
- libjetty6-jsp-java_<version>_all.deb
- libjetty6-extra-java_<version>_all.deb
- jetty6_<version>_all.deb
- jetty6-examples_<version>_all.deb
Installation Directories
The home directory for the debian distribution of jetty is /usr/share/jetty6. Other directories under /var and /etc are linked to from the /usr/share/jetty6 directory.
The configuration of the server is in /etc/jetty6. The configuration files listed in /etc/jetty6/jetty.conf are passed to the command line when it is started by /etc/init.d/jetty6.
Webapps can be deployed by placing them in /var/lib/jetty6/webapps (linked from /usr/share/jetty6/webapps). Additional contexts can be configured and (hot) deployed via the /etc/jetty6/contexts directory (linked from /usr/share/jetty6/contexts).
/usr/share/jetty6 - jetty.home directory
/contexts - webapp context files
/database - default database install dir
/etc - configuration files
/lib - jar files
/logs - log files
/resources - extra runtime config
start.jar
/webapps - webapp static deployment directory
/etc/init.d/jetty6 --> start/stop script
/etc/default/jetty6 --> default values read by start/stop script
/etc/jetty6 --> /usr/share/jetty6/etc
/etc/jetty6/contexts --> /usr/share/jetty6/contexts
/var/lib/webapps --> /usr/share/jetty6/webapps
/var/log/jetty6 --> /usr/share/jetty6/logs
/var/run/jetty6.pid --> running jetty process id
Starting/Stopping Jetty
If you have just installed the debian packages, then you will need to edit the /etc/default/jetty6 file. Make the change indicated in comment:
NO_START=1 # change to 0 to allow Jetty to start
You can now start jetty:
To stop jetty:
You can list all of the commands to control jetty by typing: