I'm attempting to start a tomcat server via the publish over ssh plugin.
I call a shell script as follows:
sudo nohup /apps/Config/usr/local/bin/ec2-init env start > /dev/null 2>&1 &
This script in turn calls the following: ec2-init > tomcat_sdb > startup.sh > catalina.sh.
Our IT guy set the following in the script tomcat_sdb:
# Protection from Jenkins ProcessTree
Killer
BUILD_ID=dontKillMe
export JAVA_HOME JAVA_OPTS PATH CUSTID
APPID INSTANCEID JBOSS_SERVER BUILD_ID
As soon as the Jenkins job terminates I can see the catalina process die.
What is the proper way to invoke this environment variable to keep the tomcat process alive after Jenkins terminates?