Change the context path used to access Jira server
Symptoms
Context paths are useful in cases where you want to either have your application resolve at http://yourdomain.com/jira or make your application unique.
Resolution
- Shut down your JIRA application instance
- Locate the
server.xml
file which located at the following path: $JIRA_installation_folder/conf/server.xml Edit
server.xml
, and add the context path inside the Context path = "" quotation area, view the example below:Example
Original:
<Context path="" docBase="${catalina.home}/atlassian-jira" reloadable="false"> </Context>
After change:
<Context path="/jira" docBase="${catalina.home}/atlassian-jira" reloadable="false"> </Context>
The path is not always in the beginning of the Context parameters, you might have to read over the entire list of parameters to find it. You can also define any word of your choosing as long as it starts with a forward slash.
For more details you can see Apache context configuration.
- Save the
server.xml
- Start your JIRA applications
- Access your applications with the context path, for example:
- Before: http://localhost:8080
- After: http://localhost:8080/jira
- Configure the 'Base URL' in JIRA Administration > Global Settings > General Configuration to the new location from which your users will access JIRA applications.
Alternative methods for setting the default Tomcat application include:
- Rename WAR file to
ROOT.war
, and re-start Tomcat.
OR - Place WAR file outside of
$CATALINA_BASE/webapps
(to avoid double deployment). Put a context file namedROOT.xml
in$CATALINA_BASE/conf/
. Set the docBase attribute to point at the location of WAR file. Leave the path element blank, as it is derived from the name of the xml file (ROOT.xml).