Overview
Bamboo can be configured to use advanced functionality such as JNDI resources and HTTPS. This is achieved through use of the jetty.xml
file, however Bamboo doesn't use this for configuration by default. To use jetty.xml
for advanced configuration, you will need to tell Bamboo to use it.
The method for doing this uses the Java Service Wrapper. Older versions of Bamboo used the bamboo.sh file.
The instructions on this page apply to the Bamboo distribution, not the Bamboo EAR-WAR distribution.
Step 1 - Instruct Bamboo to use jetty.xml
To use the Java Service Wrapper to start Bamboo:
When starting up Bamboo with the Java Service Wrapper, modify the wrapper.conf
file in the conf
directory:
- Replace the argument which specifies your port number "wrapper.app.parameter.2=8085" with "wrapper.app.parameter.2=../webapp/WEB-INF/classes/jetty.xml".
- Comment out the other arguments: "wrapper.app.parameter.3=../webapp" and "wrapper.app.parameter.4=/"
This will make Bamboo start up using your jetty.xml
configuration file instead of the default three arguments (port, web app directory, context path).
If you are using the bamboo.sh
script to start Bamboo:
The standard Bamboo startup script can be customised to use the jetty.xml
file by modifying the following section in your bamboo.sh
script (this section specifies how the Bamboo server will start):
Bamboo 3.1 and newer
Configuration is performed using the Java Service Wrapper as described above.
Bamboo 3.0
RUN_CMD="java -Xms256m -Xmx512m -Djava.awt.headless=true -classpath $CLASSPATH -Dorg.eclipse.jetty.xml.XmlParser.Validating=false -Djetty.port=8085 com.atlassian.bamboo.server.Server 8085 ./webapp /"
Now, modify this startup script to read the jetty.xml
file from webapp/WEB-INF/classes/jetty.xml
by changing the RUN_CMD argument as follows:
RUN_CMD="java -Xms256m -Xmx512m -Djava.awt.headless=true -classpath $CLASSPATH -Dorg.eclipse.jetty.xml.XmlParser.Validating=false com.atlassian.bamboo.server.Server webapp/WEB-INF/classes/jetty.xml"
Bamboo earlier than 3.0:
RUN_CMD="java -Xms256m -Xmx512m -Djava.awt.headless=true -classpath $CLASSPATH -Dorg.mortbay.xml.XmlParser.NotValidating=true -Djetty.port=8085 com.atlassian.bamboo.server.Server 8085 ./webapp /"
Now, modify this startup script to read the jetty.xml
file from webapp/WEB-INF/classes/jetty.xml
by changing the RUN_CMD argument as follows:
RUN_CMD="java -Xms256m -Xmx512m -Djava.awt.headless=true -classpath $CLASSPATH -Dorg.mortbay.xml.XmlParser.NotValidating=true com.atlassian.bamboo.server.Server webapp/WEB-INF/classes/jetty.xml"
Step 2 - Set root context web application in jetty.xml
Linux Platforms
Replace your existing <Bamboo-install>/webapp/WEB-INF/classes/jetty.xml
file, with this jetty.xml file.
Windows Platforms
Replace your existing <Bamboo-install>\webapp\WEB-INF\classes\jetty.xml file, with this jetty.xml file.
Attachments:





