Configure base URL for Confluence, JIRA and Bitbucket Edited

Hello,

We have bought the license for Bitbucket, JIRA and Confluence and installed the same. We are using a URL to access this applications like http://<servername>:7990/Bitbucket now. We need to configure this base url to something like http://jira.<companyname>.corp.net for all the applications. Is it straightforward as I changed the Context path in server.xml or is it mandatory to have a DNS like above. I have gone through the below URL and I need to know if that is the only way I can achieve this.

https://confluence.atlassian.com/kb/proxying-atlassian-server-applications-with-apache-http-server-mod_proxy_http-806032611.html

Any help much appreciated.

Thanks,

Prasanna

3 answers

Hi Prasanna.

I recently configured our Jira + Bitbucket in the same machine, and later on added a proxy (I guess Confluence will be similar to Jira)

You'll need to touch server.xml to add a second connector (or modify an existing one), and configure your app base url (via GUI normally)

Of course you'll need some kind of DNS entry to resolve jira.<companyname>.corp.net, otherwise no user will find it.

A couple of issues I ran into: 

Make sure that you use the same context path in your external proxy as for your internal app:

http://jira.<companyname>.corp.net/bitbucket points to http://<servername>:7991/bitbucket

NOTE that I wrote the context in lowercase (less problems that way), and that I redirected to a different internal port 7991. In order to facilitate discerning problems with the proxy, I found it better if I kept the original connector on 7990 as it was, and configured an additional one on a different port (7991) to be accesible via proxy (see the doc you pointed at). This way if you can't access via proxy, a priviledged internal user can still test the direct access to the internal server, and check if it's a problem with the proxy or not.

Hope any of this helped.

Best regards,

  Agustín.

On my previous answer I was asuming you wanted to add a proxy in front of your internal server.

If you don't and you just want to access your internal server directly with a different URL, you'll just need to change the base url, and add the proper entry to your DNS (and internal server's etc/host). No need to configure additional connectors.

Might need to change your internal hostname also.

Hello Agustin,

Thanks for your response.

I just need to access the applications with the URL's mentioned in the above question.

Current URL: http://<servername>:<port no>/jira

Required URL: http://jira.<companyname>.corp.net

As mentioned above the context path of the URL's are different. Also, I dont need the current URL anymore once the new one is configured. Please let me know if changing the base URL and DNS will suffice in this case.

Thanks,

Prasanna

Hello Agustin,

As mentioned by you in the above message, I did the below steps,

1. Modified hosts file for DNS in C:\Windows\System32\drivers\etc - Added the entry like below

<IP Address> jira.<company-name>.corp.net

2. Changed the Base URL - http://jira.<company-name>.corp.net in JIRA GUI

3. Restarted the JIRA service

Now, when I hit the above URL, it is getting redirected to IIS page. I am not sure why. Could you please suggest if I have missed anything.

Thanks,

Prasanna

@prasanna sorry for the late reply.

If you had configured a context before, you'd need to remove it now (edit your jira's server.xml file).

Other than that, it should work just by changing the base URL in jira and putting the right entry in your DNS

Note that changing the etc/hosts in one machine will only fix it for that machine you're modifying. If you want the new URL to work for more clients, it's normally better to add the entry to the DNS managing your domain (<company-name>.corp.net)

Best regards,

   Agustín.

Hello Agustin,

Thanks for the response.

I have followed your above steps but I am still getting redirected to IIS page. Do you have any idea why this happening? I have added the DNS entry in my local machine. Firstly I would need to check if the above settings working in my local machine so that I can add the DNS entry in the company domain.

Your inputs highly appreciated.

Thanks,

Prasanna

Hello Agustin,

Thanks for your response.

I just need to access the applications with the URL's mentioned in the above question.

Current URL: http://<servername>:<port no>/jira

Required URL: http://jira.<companyname>.corp.net

As mentioned above the context path of the URL's are different. Also, I dont need the current URL anymore once the new one is configured. Please let me know if changing the base URL and DNS will suffice in this case.

Thanks,

Prasanna

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Oct 16, 2018 in Jira

Looking for anyone who made the switch to Data Center

The Jira Marketing team is putting together an ebook on migrating to Data Center. We're looking for pro tips on how you staffed your project team and organized your Proof of Concept. Share yo...

1,392 views 17 10
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you