#!/bin/sh
#
# Startup script for Jetty with systemd
#

set -e

# Load the service settings
. /etc/default/jetty12

# Find the Java runtime and set JAVA_HOME
. /usr/libexec/jetty12/jetty-locate-java.sh

# Start Jetty
cd $JETTY_BASE && $JAVA_HOME/bin/java $JAVA_OPTIONS -jar $JETTY_HOME/start.jar -Djetty.base=$JETTY_BASE $JETTY_ARGS
