How to change the hostname of the server where our bitbucket is installed,

We have a need to change the OS level hostname of the server where our bitbucket was installed ( say from serverX to clientX) . what changes needs to be done on the bitbucket server side. Our installation uses postgresql databases on same server as the bitbucket server.

1 answer

1 accepted

0 votes
Answer accepted

Check the file - that has the database connection, which you may need to change if you've used a host name in there instead of localhost

Then change the "base url" for in server settings, if you are using the hostname directly.

I have checked and my database connection properties is set to local host.

So, once we change the OS level server hostname, the only thing that need to be change is the "base url" in server settings?


I am wondering if there is any hostname hard-coded anywhere in the application directory structure or the underlying database.




Nope.  Just the base url.

It's never hard-coded because the developers cannot possibly know where you are going to install it.  I suspect my understanding of "hard coded" is different to yours.  To me, it means "there is code that says X, that gets compiled and can't be changed without hacking the executables".  I think you might mean "config that gets decided at install time and does not change afterwards" - Atlassian applications don't do that, they accept setup stuff, but try to keep it in one place and allow you to change it later, which is a good thing.  The base url is very important to Atlassian applications, but you only have to change it in one place.



Thank you Nic!. I have implemented the change and it worked.


Yes, you are right, by hard-coded, I meant "that it was probably set during the install time and stored in a config file somewhere withing the application structure.

This design is very flexible...that is awsome!/

Suggest an answer

Log in or Sign up to answer
Community showcase
Published Mar 14, 2019 in Bitbucket Pipelines

Building a Bitbucket Pipe as a casual coder :  #!/bin/bash source "$(dirname "$0")/" enable_debug extra_args="" if [[ "${DEBUG}" == "true" ]]; then extra_args="--verbose" fi # mandatory variables R...

274 views 0 12
Read article

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