Integrate Jira Server with IIS Using Application Request Routing
Platform Notice: Data Center Only - This article only applies to Atlassian products on the Data Center platform.
Note that this KB was created for the Data Center version of the product. Data Center KBs for non-Data-Center-specific features may also work for Server versions of the product, however they have not been tested. Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.
*Except Fisheye and Crucible
Summary
This article provides a comprehensive guide on integrating Jira Server with Microsoft's IIS using Application Request Routing (ARR). It outlines the necessary configurations and steps to ensure seamless integration, enhancing the routing capabilities and management of Jira applications. The guide is essential for administrators looking to optimize their Jira Server setup with IIS, leveraging ARR for improved performance and reliability.
Solution
Install Application Request Routing and URL Rewriting on your IIS server.
Enable Proxying on ARR:
From the IIS7 Console, click on Server_Name and open Application Request Routing:
From the Actions panel on the right hand side, select "Server Proxy Settings"
Check "Enable Proxy" and set HTTP Version to "HTTP/1.1":
Make sure to disable "Reverse Rewrite Host in Response Headers" - this can cause problems with URLs being re-written incorrectly:
Click on your Server in the sidebar
Click "Application Request Routing Cache"
Click "Server Proxy Settings"
Untick "Reverse rewrite host in response headers"
Add a new site on IIS (e.g, jira.example.com).
Add a new URL Rewrite Rule for jira.example.com:
From the IIS7 Console, click on jira.example.com and open URL Rewrite:
From the Actions panel on the right hand side, select "Add Rules" and choose "Blank Rule";
Set Match URL to:
Requested URL: Matches the Pattern
Using: Regular Expressions
Pattern: (.*)
Ignore Case: Checked
Set Action to:
Action Type: Rewrite
Rewrite URL: http://<JIRA_url:Port>/{R:1}
Append query string: Checked
Mark Stop processing of subsequent rules;
Click on Request Filtering
Then click on Edit Feature Settings
Check Allow double escaping and hit OK
Now add this comment to your
<jira-install>/conf/server.xml
:<Connector port="8080" connectionTimeout="20000" redirectPort="8443" maxThreads="200" minSpareThreads="10" enableLookups="false" acceptCount="10" debug="0" URIEncoding="UTF-8" />
Add the parameters proxyName and proxyPort to your
<JIRA-install-directory>/conf/server.xml
file in Jira, as in this example:<Connector acceptCount="100" connectionTimeout="20000" disableUploadTimeout="true" enableLookups="false" maxHttpHeaderSize="8192" maxSpareThreads="75" maxThreads="150" minSpareThreads="25" port="8080" protocol="HTTP/1.1" redirectPort="8443" useBodyEncodingForURI="true" proxyName="jira.example.com" proxyPort="80"/>
Restart your Jira application.
Optional
In some cases more than one site will be hosted in the same IIS installation. In case you want to have a subdomain structure (i.e. jira.example.com, confluence.example.com), you may create different sites as follow:
Create an A Record in the DNS for your subdomain and point to the same IP:
Create new sites (step 3 of the instructions above) for each one of your subdomains:
Sites > Add Website
Site Name: subdomain.example.com
Physical Path: select the subdomain directory
Binding: same IP as example.com
Host name: subdomain.example.com
Known Issues
Elements in Jira server fail to render with 400 bad request error
User session changed or hijacked in Jira server integrated with IIS
HTTP Error 500.51 when attempting to access Jira through IIS
Was this helpful?