Skip to content

Instantly share code, notes, and snippets.

@facholi
Created February 27, 2015 20:28
Show Gist options
  • Save facholi/754a6d7077cfe4dd0601 to your computer and use it in GitHub Desktop.
Save facholi/754a6d7077cfe4dd0601 to your computer and use it in GitHub Desktop.
# download jetty
sudo wget http://download.eclipse.org/jetty/stable-9/dist/jetty-distribution-9.2.9.v20150224.tar.gz
# unpack it
sudo tar zxvf jetty-distribution-9.2.9.v20150224.tar.gz
# create a simbolic link
ln -s jetty-distribution-9.2.9.v20150224/ jetty
# it make the command 'service jetty start' possible
sudo cp jetty/bin/jetty.sh /etc/init.d/jetty
# run jetty on initialization
chkconfig --add jetty
chkconfig --level 345 jetty on
# make a file /etc/default/jetty to export some need variables like:
# JAVA_HOME=/usr/java/default/jre
# JAVA_OPTIONS="$JAVA_OPTIONS -server -Dfile.encoding=UTF-8 -Xms1G -Xmx1800m"
# JETTY_HOME=/opt/jetty
# JETTY_USER=root
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment