Installation - Java Linux Agent on a Jetty Application Server
Jetty Compatibility
vFunction supports Eclipse Jetty version 9.4.20 and later.
Installation Wizard
To help with the installation process, vFunction offers an Installation Wizard. This Wizard provides additional information about the Prerequisites as well as the Required and Optional Settings for installing the vFunction Server and Agents. This Wizard also walks you through each step in the Installation process.
Please contact support@vfunction.com or your vFunction Contact(s) for the password to start using this Wizard.
Installation Workflow
- Ensure Prerequisites are met
- Download the vFunction Sudoless Controller Installation TGZ
- SSH to the Linux VM as the user who runs the Application / Application Server
- Move the Installation TGZ to the location on the Linux VM where vFunction should run
- Extract the vFunction Installation Package
### Replace VERSION with the actual value
tar -xvzf vfunction-controller-sudo-less-installation.vVERSION.tgz
- Add Environment Variables for the vFunction Dynamic Agent
# See description in https://kb.vfunction.com/installations/configurable-settings/mono-dynamic-agent/java/linux
export VF_CONTROLLER_DEFAULT_JAVA_CONTROLLER_NAME="CHANGE_ME"
export VF_CONTROLLER_DEFAULT_JAVA_CONTROLLER_HOST="CHANGE_ME"
export VF_CONTROLLER_DEFAULT_JAVA_CONTROLLER_ORG_ID="CHANGE_ME"
export VF_CONTROLLER_DEFAULT_JAVA_CONTROLLER_APP_ID="CHANGE_ME"
export VF_CONTROLLER_DEFAULT_JAVA_CONTROLLER_CLIENT_ID="CHANGE_ME"
export VF_CONTROLLER_DEFAULT_JAVA_CONTROLLER_CLIENT_SECRET="CHANGE_ME"
export VF_CONTROLLER_DEFAULT_JAVA_CONTROLLER_INSTANCE_ID="CHANGE_ME"
export VF_CONTROLLER_DEFAULT_JAVA_AGENT_APPLICATION_SERVER="CHANGE_ME"
export VF_CONTROLLER_DEFAULT_JAVA_AGENT_APPLICATION_JAVA_VERSION="CHANGE_ME"
- Run the installation script
### Replace the BASE_DIR with the actual value, such as /tmp/
bash BASE_DIR/vfunction/opt/vfunction/controller-installation/install.sh -i default-java
- Find and note the base path to your Jetty Application Server
### This should return the location of the bin/setenv.sh which should be in the Jetty Application Server's JETTY_HOME
find / -name 'jetty.sh' -type f 2&>/dev/null
- Open the Jetty Application Server’s Startup Script in a text editor
### Replace the JETTY_HOME with the actual value
vi JETTY_HOME/bin/jetty.sh
- Find the section of the file for setting the Java VM options
/Java VM options
- Add a section for the vFunction Startup Parameters above the comment to “Add jetty properties to Java VM options.” Copy and paste the details below.
#####################################################
# Add vFunction options
#####################################################
JAVA_OPTIONS="$JAVA_OPTIONS $VFUN_OPTS"
- Create a variable with the vFunction Agent Startup Parameters
### Replace the BASE_DIR with the actual value, such as /tmp/
export VFUN_OPTS=`cat BASE_DIR/vfunction/etc/sysconfig/vfunction/agent/instances/default-java/vmargs-examples/raw`
- Restart the Jetty instance
- Confirm that the Application comes up and functions as expected
- If any issues arise: